Skip to content

Instantly share code, notes, and snippets.

@LinuxDevOpsGirl
Created December 12, 2021 09:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LinuxDevOpsGirl/a1707ade349013e580538739042ba85e to your computer and use it in GitHub Desktop.
Save LinuxDevOpsGirl/a1707ade349013e580538739042ba85e to your computer and use it in GitHub Desktop.
Drupal Install LEMP Stack
# Install NGINX
apt update
apt install nginx
sudo -i
apt install mariadb-server mariadb-client
mysql_secure_installation
apt update -y
apt upgrade -y
apt install php php-mysql php-fpm
systemctl stop apache2
systemctl restart nginx
systemctl reload nginx
systemctl status nginx
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php -r "if (hash_file('sha384', 'composer-setup.php') === '756890a4488ce9024fc62c56153228907f1545c228516cbf63f885e036d37e9a59d27d63f46af1d4d07ee0f76181c7d3') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
php composer-setup.php
php composer.phar update
php composer.phar install
sudo mv composer.phar /usr/local/bin/composer
php -r "unlink('composer-setup.php');"
nginx -t
systemctl restart nginx
systemctl reload nginx
systemctl status nginx
@LinuxDevOpsGirl
Copy link
Author

Screenshot from 2021-12-12 02-58-09

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment