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
uname -r | |
or | |
uname -a | |
cat /etc/lsb-release | |
cat /etc/os-release |
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
# Login as root & update and upgrade the os: | |
apt update | |
apt upgrade | |
apt install sudo | |
# Give a user access to use sudo | |
usermod -aG suo USERNAM |
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 | |
echo "===============================" | |
echo "Installing PHP 7" | |
echo "===============================" | |
sudo yum install php70 | |
echo "===============================" | |
echo "Installing PHP 7 additional commonly used php packages" | |
echo "===============================" |
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
source ~/.bash_profile |
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
# romeve image by name | |
docker rmi <image name> | |
## romve all images | |
docker rmi $(docker images -a -q) |
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
# get nvm manager | |
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash | |
#install nodejs version you need | |
nvm install v10.15.0 |
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
# Will return 'arm', 'ia32', or 'x64' | |
node -p "process.arch" |
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
# Display current mode | |
bin/magento deploy:mode:show | |
# Change mode | |
bin/magento deploy:mode:set developer | production | default |
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
# https://magemojo.com/kb/knowledge-base/clear-magento-2-cache/ | |
php bin/magento cache:flush | |
php bin/magento cache:clean |
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
#https://www.liquidweb.com/kb/delete-a-mysql-database-on-linux-via-command-line/ | |
# Login to the MySQL server using root | |
mysql -u root -p | |
# show all dbs | |
SHOW DATABASES; | |
# Delete a db | |
DROP DATABASE IF EXISTS db_name; |