Created
July 16, 2019 19:58
-
-
Save RafikFarhad/afe8d81ee9c3565da8e24247f581685f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
mode=$1 | |
if [ "$mode" = "stop" ] | |
then | |
echo -e "Stopping Services..." | |
sudo service nginx stop | |
sudo service mysql stop | |
sudo service php7.3-fpm stop | |
sudo service redis-server stop | |
echo -e "!~Enjoy~!" | |
else if [ "$mode" = "start" ] | |
then | |
echo -e "Starting Services..." | |
sudo service nginx start | |
sudo service mysql start | |
sudo service php7.3-fpm start | |
sudo service redis-server start | |
echo -e "!~Enjoy~!" | |
else | |
echo "Command Not Found. Possible Commands [ start|stop ]" | |
fi | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment