Skip to content

Commit ed1c2f2

Browse files
authored
back inside the loop
1 parent 1acf3c5 commit ed1c2f2

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

apache2-deployer.sh

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -193,24 +193,24 @@ fn_web_directory(){
193193
else
194194
mkdir -pv "${targetdir}"
195195
echo "[OK] Directory created!"
196-
echo ""
197-
echo "Applying correct ownership & permissions to the website folder..."
198-
sleep 1
199-
chown -R "${username}":"${username}" "${targetdir}"
200-
chmod -R 770 "${targetdir}"
201-
chmod -R g+s "${targetdir}"
202-
echo "[OK] Ownership & permissions set!"
203-
echo ""
204-
echo "Adding ${username} group to ${apacheprocess}..."
205-
sleep 2
206-
usermod -a -G "${username}" "${apacheprocess}"
207-
echo "[OK] Added user group to ${apacheprocess}!"
208-
echo ""
209-
echo "Restarting apache2 to enable group modifications..."
210-
sleep 1
211-
service apache2 restart
212-
echo "[OK] apache2 restarted!"
213196
fi
197+
echo ""
198+
echo "Applying correct ownership & permissions to the website folder..."
199+
sleep 1
200+
chown -R "${username}":"${username}" "${targetdir}"
201+
chmod -R 770 "${targetdir}"
202+
chmod -R g+s "${targetdir}"
203+
echo "[OK] Ownership & permissions set!"
204+
echo ""
205+
echo "Adding ${username} group to ${apacheprocess}..."
206+
sleep 2
207+
usermod -a -G "${username}" "${apacheprocess}"
208+
echo "[OK] Added user group to ${apacheprocess}!"
209+
echo ""
210+
echo "Restarting apache2 to enable group modifications..."
211+
sleep 1
212+
service apache2 restart
213+
echo "[OK] apache2 restarted!"
214214
}
215215

216216
# Create the Virtual Host config file and enable the site in apache

0 commit comments

Comments
 (0)