Last active
July 28, 2019 11:50
-
-
Save ahmeti/7261f5a0c13b1461388253ea0a3375a3 to your computer and use it in GitHub Desktop.
Amazon AWS üzerinde Ubuntu 18.04, Nginx, Php 7.2, Mysql 8 Kurulumu
This file contains 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
sudo service apache2 stop | |
sudo apt-get purge apache2* | |
sudo apt-get autoremove | |
whereis apache2 | |
sudo rm -rf /etc/apache2 |
This file contains 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
sudo apt update | |
sudo apt install nginx |
This file contains 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
sudo apt install php7.2-fpm | |
sudo apt install composer | |
sudo apt install php7.2-bcmath | |
php-fpm7.2 -v | |
sudo apt install php7.2-common | |
sudo apt install php7.2-mysql | |
sudo apt install php7.2-xml | |
sudo apt install php7.2-xmlrpc | |
sudo apt install php7.2-curl | |
sudo apt install php7.2-gd | |
sudo apt install php7.2-imagick | |
sudo apt install php7.2-cli | |
sudo apt install php7.2-dev | |
sudo apt install php7.2-imap | |
sudo apt install php7.2-mbstring | |
sudo apt install php7.2-opcache | |
sudo apt install php7.2-soap | |
sudo apt install php7.2-zip | |
sudo apt install php7.2-intl -y |
This file contains 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
wget -c https://dev.mysql.com/get/mysql-apt-config_0.8.10-1_all.deb | |
sudo dpkg -i mysql-apt-config_0.8.10-1_all.deb | |
sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 5072E1F5 | |
sudo apt update | |
sudo apt-get install mysql-server | |
sudo mysql_secure_installation | |
Remove anonymous users? Y | |
Disallow root login remotely? Y | |
Remove test database and access to it? Y | |
Reload privilege tables now? Y | |
set global log_bin_trust_function_creators = 1; | |
CREATE DATABASE mydatabase CHARACTER SET utf8 COLLATE utf8_general_ci; | |
CREATE USER 'myuser'@'localhost' IDENTIFIED WITH mysql_native_password BY 'mypass'; | |
GRANT ALL PRIVILEGES ON mydatabase.* TO 'myuser'@'localhost'; | |
FLUSH PRIVILEGES; |
This file contains 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
nano /etc/php/7.2/fpm/php.ini | |
max_execution_time = 180 | |
max_input_time = 180 | |
max_input_vars = 1500 | |
memory_limit = 256M | |
post_max_size = 20M | |
upload_max_filesize = 20M |
This file contains 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
nano /etc/nginx/nginx.conf | |
http { | |
## | |
# Basic Settings | |
## | |
client_max_body_size 20M; # Add this line in http block | |
## | |
# SSL Settings | |
## | |
ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2; # Update this line in http block | |
ssl_prefer_server_ciphers on; | |
ssl_session_timeout 5m; # Add this line in http block | |
ssl_ciphers "HIGH:!aNULL:!MD5 or HIGH:!aNULL:!MD5:!3DES"; # Add this line in http block | |
} |
This file contains 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
sudo chown -R www-data:www-data /path/to/your/website |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment