diff --git a/main/dismantle_instance.sh b/main/dismantle_instance.sh index a4eaa2f..6c7942c 100755 --- a/main/dismantle_instance.sh +++ b/main/dismantle_instance.sh @@ -67,6 +67,6 @@ endnumber=$(( $linenumber + 7 )) sed -i "${linenumber},${endnumber}d" $SSHCONFIG # remove $NAME from $DATASOURCE -linenumber=$(grep -n "name: $NAME" $DATASOURCE | cut -d":" -f1) +linenumber=$(sudo grep -n "name: $NAME" $DATASOURCE | cut -d":" -f1) endnumber=$(( $linenumber + 6 )) sudo sed -i "${linenumber},${endnumber}d" $DATASOURCE