Skip to content

Instantly share code, notes, and snippets.

@rafamancan
Last active August 17, 2019 15:09
Show Gist options
  • Save rafamancan/e72033129da2b042e4a9f686d6671a7e to your computer and use it in GitHub Desktop.
Save rafamancan/e72033129da2b042e4a9f686d6671a7e to your computer and use it in GitHub Desktop.
sudo apt update
sudo apt upgrade -y
sudo apt install -y apache2
sudo apt install -y php php-cli php-common php-gd php-mbstring php-intl php-xml php-zip php-pear libapache2-mod-php
echo “<?php phpinfo(); ?>” | sudo tee /var/www/html/test.php | sudo service apache2 restart
sudo apt install -y mysql-server mysql-client php-mysql
sudo mysql
CREATE USER 'seu_usuario'@'localhost' IDENTIFIED BY 'sua_senha';
GRANT ALL PRIVILEGES ON *.* TO 'seu_usuario'@'localhost' WITH GRANT OPTION;
FLUSH PRIVILEGES;
sudo mysql -u seu_usuario -p
sudo a2enmod rewrite
sudo nano /etc/apache2/apache2.conf
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
sudo /etc/init.d/apache2 restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment