From dd7a71bc448cfe066c9299c805df9d68f61e1af3 Mon Sep 17 00:00:00 2001 From: ralumbi Date: Wed, 22 Apr 2020 22:18:38 +0200 Subject: [PATCH 1/7] setup-webserver-linux book --- .../setup-webserver-linux.md | 178 ++++++++++++++++++ 1 file changed, 178 insertions(+) create mode 100644 running-your-first-ot-server/setup-webserver-linux.md diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md new file mode 100644 index 0000000..bac308d --- /dev/null +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -0,0 +1,178 @@ +# Setting up your ubuntu linux server +guiding to setup your very own ubuntu linux server with a webserver plus the ability to deploy your tfs server + +> We are not responsible for the mistakes you make + +# Getting started +Rent a ubuntu server 18.04 or higher from a trusted hosting company such as ovh.com or install for the sake of learning experience ubuntu server 18.04 or higher on another computer or if you are on windows use virtualbox to get your ubuntu server. + +Once you're set we will start by accessing our server. If you're on windows you should get putty(click here), if you're on macOS or Linux you can use the terminal which is standard available. With putty just follow the screen ( insert your domain/ip-address and click ok ) for macOS and linux users type: + +```bash +ssh username@domain/ipaddress +``` +`username example => root +domain/ipaddress example => yourdomain.com or 127.0.0.1` + +Now you will be prompted for your password (if in putty you will be prompted for the password as soon you click on Open) Insert your password and presh enter (you will not see what you type, so make sure you type your password in the right order). Now we are in our server :) + +## Update and Upgrade the system +The first thing we will do is updating our ubuntu server with the following command +```bash +sudo apt update && sudo apt upgrade -y +``` +We are using 'sudo' since I do not know if you're running as root user or as regular user. When you're logged in as regular user. No problem! Just enter your password when the terminal asks for your password. With the command above you will update the connected repository's the server is connected to and when the server is done updating the repository's it will directly upgrade all the packages which were updated. + +# Installing the webserver + +Now we will get to the more difficult part of the entire server setup, installing nginx, php-fpm, mariadb-server with phpmyadmin. +```bash +sudo apt install nginx php-fpm mariadb-server -y +``` +The installation process is now triggered.When this is finished we will install phpmyadmin to handle our database server (which is mariadb) +```bash +sudo apt install phpmyadmin -y +``` +Now we are set to get some configurations going! + +## Configuring the webserver +First we want to know which version of php-fpm is installed we will check this by writing the following command in the terminal +```bash +sudo php -v +``` +The output will be looking something similar as this (I am using ubuntu 19.10 here which uses php version 7.3 as default. If you're running on a server you most likely run on 18.04 lts or with the newest version 20.04 lts): + +![alt text](https://worldofcoding.com/github/images/otland-gitbook/phpversion.png "phpversion") + +Second we want to do is enabling php in our nginx server and setting the configuration just as we want. So we will be going to edit our nginx config. Now we need to install a command line text editor called "vim". After that we installed it we will directly open the configuration file. +```bash +sudo apt install vim -y && sudo vim /etc/nginx/sites-available/default +``` + +Now sit straight up and read carefully on what we're going to do. I am going to give you a few options in the configuration. Underneath here you will find the default configuration file of nginx. ( I only took the part of the config file we are in need to use and left out all the comments which we do use in this tutorial ) + +## Changing the web-root + +We can change the 'root' directory of the website folder, if you're only using your server as root leave it in '/var/www/html'. When using it as for example 'john' you can change the directory to your default directory when you come when you login which is: '/home/john' in the default directory of john you can do 'mkdir www' to create a directory for the website and set: '/home/john/www' on line '5' instead of '/var/www/html'. + +## Configuring php + +I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which ubuntu server version you are running ( and assuming you're using ubuntu server 18.04 lts ). +```bash +server { + listen 80 default_server; + listen [::]:80 default_server; + + root /var/www/html; + + # Add index.php to the list if you are using PHP + index index.php index.html index.htm index.nginx-debian.html; + + server_name _; + + location / { + # First attempt to serve request as file, then + # as directory, then fall back to displaying a 404. + try_files $uri $uri/ =404; + } + + # pass PHP scripts to FastCGI server + # + location ~ \.php$ { + include snippets/fastcgi-php.conf; + # + # # With php-fpm (or other unix sockets): + ################## UBUNTU 18.04 LTS ################## + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + ################## UBUNTU 20.04 LTS ################## + # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + + } + +} + +``` +Now we have to save the file and quit the file, we do this the following way: +`CTRL+C` After that you will just write `:wq` press enter and we have saved and quit the file :) + +We are set with the entire webserver now and so its time to check if we actually did everything as we supposed to do, but first we have to restart our web features. We do this with the following commands: +`Change the number of the php-fpm version to one you're using!!!` +```bash +sudo systemctl restart nginx +sudo systemctl restart php7.2-fpm +``` +Lets open our browser and goto your ip-address and see how wonderful you are! +Your very own setup and configured server! + +# Setup the database user + phpmyadmin + +We need to create ourselves a mysql admin account. We will be doing this the following way. Please follow the steps carefully :) + +```bash +sudo mariadb +``` +![alt text](https://worldofcoding.com/github/images/otland-gitbook/mariadb.png "mariadb") +###### You are inside the database right now! + +We will be creating the user 'otadmin' with the password of 'otadminpassword', change these values to what you want it to be! +```bash +create user 'otadmin'@'localhost' identified by 'otadminpassword'; +grant all privileges on *.* to 'otadmin'@'localhost'; +flush privileges; +exit; +``` +Insert these lines one by one. +Now we have setup our database superuser :) + +## Configure phpmyadmin +Setup phpmyadmin to access your database via the browser. + +Insert the following configuration in a new file inside the nginx folder. The following command will create the file and when you are in insert the configuration posted below. +( same as for the webserver nginx configuration I have made comments for the ubuntu versions inside the php location ) +`sudo vim /etc/nginx/sites-available/phpmyadmin` +```bash +server { + listen 2344; + server_name _; + root /usr/share/phpmyadmin; + + add_header X-Frame-Options DENY; + add_header X-Content-Type-Options nosniff; + add_header X-XSS-Protection "1; mode=block"; + + client_max_body_size 256M; + error_page 404 @notfound; + + location / { + index index.html index.php; + try_files $uri $uri/ /index.php?$args; + } + + location ~* \.(gif|jpg|jpeg|png|bmp|js|css)$ { + expires max; + } + + location ~ \.php$ { + include snippets/fastcgi-php.conf; + + ################## UBUNTU 18.04 LTS ################## + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + ################## UBUNTU 20.04 LTS ################## + # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + + } + + location @notfound { + return 404 "You're not browsing correctly."; + add_header Content-Type text/plain always; + } + +} +``` +Now we have to save the file and quit the file, we do this the following way: +`CTRL+C` After that you will just write `:wq` press enter and we have saved and quit the file :) + +Now we have to enable the phpmyadmin configuration for nginx we do that by running the next command: +`sudo ln -s /etc/nginx/sites-available/phpmyadmin /etc/nginx/sites-enabled/phpmyadmin` + +Finally restart the nginx server with `sudo systemctl restart nginx` and we will be able to access phpmyadmin by http://youripordomain:2344 login with the database username and password we've created. From 7d6d1e9edf80eff285d506b7d2d946e7169e1845 Mon Sep 17 00:00:00 2001 From: Caleb <36135509+Ralumbi@users.noreply.github.com> Date: Wed, 22 Apr 2020 22:23:52 +0200 Subject: [PATCH 2/7] Update setup-webserver-linux.md --- running-your-first-ot-server/setup-webserver-linux.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index bac308d..b1e8343 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -42,7 +42,7 @@ sudo php -v ``` The output will be looking something similar as this (I am using ubuntu 19.10 here which uses php version 7.3 as default. If you're running on a server you most likely run on 18.04 lts or with the newest version 20.04 lts): -![alt text](https://worldofcoding.com/github/images/otland-gitbook/phpversion.png "phpversion") +![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") Second we want to do is enabling php in our nginx server and setting the configuration just as we want. So we will be going to edit our nginx config. Now we need to install a command line text editor called "vim". After that we installed it we will directly open the configuration file. ```bash @@ -111,7 +111,7 @@ We need to create ourselves a mysql admin account. We will be doing this the fol ```bash sudo mariadb ``` -![alt text](https://worldofcoding.com/github/images/otland-gitbook/mariadb.png "mariadb") +![alt text](https://worldofcoding.net/github-img/otland-gitbook/mariadb.png "mariadb") ###### You are inside the database right now! We will be creating the user 'otadmin' with the password of 'otadminpassword', change these values to what you want it to be! From 93ced2f44cf25a454e73a67c9a3d2a6b7adb9ca8 Mon Sep 17 00:00:00 2001 From: ralumbi Date: Sun, 26 Apr 2020 08:50:35 +0200 Subject: [PATCH 3/7] changed text, added TFS guiding --- .../setup-webserver-linux.md | 45 ++++++++++++++----- 1 file changed, 34 insertions(+), 11 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index b1e8343..6cb49b9 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -1,12 +1,7 @@ -# Setting up your ubuntu linux server -guiding to setup your very own ubuntu linux server with a webserver plus the ability to deploy your tfs server - -> We are not responsible for the mistakes you make - # Getting started -Rent a ubuntu server 18.04 or higher from a trusted hosting company such as ovh.com or install for the sake of learning experience ubuntu server 18.04 or higher on another computer or if you are on windows use virtualbox to get your ubuntu server. +Rent a Ubuntu Server 18.04 or higher from a trusted hosting company such or install for the sake of learning experience Ubuntu Server 18.04 or higher in VirtualBox. -Once you're set we will start by accessing our server. If you're on windows you should get putty(click here), if you're on macOS or Linux you can use the terminal which is standard available. With putty just follow the screen ( insert your domain/ip-address and click ok ) for macOS and linux users type: +Once you're set we will start by accessing our server. If you're on windows you should get putty(https://www.putty.org/), if you're on macOS or Linux you can use the terminal which is standard available. With putty just follow the screen ( insert your domain/ip-address and click ok ) for macOS and linux users type: ```bash ssh username@domain/ipaddress @@ -17,7 +12,7 @@ domain/ipaddress example => yourdomain.com or 127.0.0.1` Now you will be prompted for your password (if in putty you will be prompted for the password as soon you click on Open) Insert your password and presh enter (you will not see what you type, so make sure you type your password in the right order). Now we are in our server :) ## Update and Upgrade the system -The first thing we will do is updating our ubuntu server with the following command +The first thing we will do is updating our Ubuntu Server with the following command ```bash sudo apt update && sudo apt upgrade -y ``` @@ -42,7 +37,7 @@ sudo php -v ``` The output will be looking something similar as this (I am using ubuntu 19.10 here which uses php version 7.3 as default. If you're running on a server you most likely run on 18.04 lts or with the newest version 20.04 lts): -![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") +![alt text](https://worldofcoding.com/github/images/otland-gitbook/phpversion.png "phpversion") Second we want to do is enabling php in our nginx server and setting the configuration just as we want. So we will be going to edit our nginx config. Now we need to install a command line text editor called "vim". After that we installed it we will directly open the configuration file. ```bash @@ -57,7 +52,7 @@ We can change the 'root' directory of the website folder, if you're only using y ## Configuring php -I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which ubuntu server version you are running ( and assuming you're using ubuntu server 18.04 lts ). +I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which Ubuntu Server version you are running ( and assuming you're using Ubuntu Server 18.04 lts ). ```bash server { listen 80 default_server; @@ -111,7 +106,7 @@ We need to create ourselves a mysql admin account. We will be doing this the fol ```bash sudo mariadb ``` -![alt text](https://worldofcoding.net/github-img/otland-gitbook/mariadb.png "mariadb") +![alt text](https://worldofcoding.com/github/images/otland-gitbook/mariadb.png "mariadb") ###### You are inside the database right now! We will be creating the user 'otadmin' with the password of 'otadminpassword', change these values to what you want it to be! @@ -176,3 +171,31 @@ Now we have to enable the phpmyadmin configuration for nginx we do that by runni `sudo ln -s /etc/nginx/sites-available/phpmyadmin /etc/nginx/sites-enabled/phpmyadmin` Finally restart the nginx server with `sudo systemctl restart nginx` and we will be able to access phpmyadmin by http://youripordomain:2344 login with the database username and password we've created. + +# Setup your Server for TFS +First of all we need to install a few packages to our system which makes us able to build the TFS sources. + +Directly copy'd from the TFS github wiki(https://github.com/otland/forgottenserver/wiki/Compiling-on-Ubuntu): +## Install the required software + +The following command will install Git, CMake, a compiler and the libraries used by The Forgotten Server. + +Git will be used to download the source code, and CMake will be used to generate the build files. +```bash +sudo apt-get install git cmake build-essential liblua5.2-dev libgmp3-dev libmysqlclient-dev libboost-system-dev libboost-iostreams-dev libboost-filesystem-dev libpugixml-dev libcrypto++-dev +``` +## Download the source code + +```bash +git clone --recursive https://github.com/otland/forgottenserver.git +``` +## Generate the build files +```bash +cd forgottenserver +mkdir build && cd build +cmake .. +``` +## Build +```bash +make +``` \ No newline at end of file From 40f0f5dc3d27bf9a1226fe280f1b85c2e70efee7 Mon Sep 17 00:00:00 2001 From: Caleb <36135509+Ralumbi@users.noreply.github.com> Date: Sun, 26 Apr 2020 08:58:03 +0200 Subject: [PATCH 4/7] fixed image location url --- running-your-first-ot-server/setup-webserver-linux.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index 6cb49b9..c434440 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -37,7 +37,7 @@ sudo php -v ``` The output will be looking something similar as this (I am using ubuntu 19.10 here which uses php version 7.3 as default. If you're running on a server you most likely run on 18.04 lts or with the newest version 20.04 lts): -![alt text](https://worldofcoding.com/github/images/otland-gitbook/phpversion.png "phpversion") +![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") Second we want to do is enabling php in our nginx server and setting the configuration just as we want. So we will be going to edit our nginx config. Now we need to install a command line text editor called "vim". After that we installed it we will directly open the configuration file. ```bash @@ -106,7 +106,7 @@ We need to create ourselves a mysql admin account. We will be doing this the fol ```bash sudo mariadb ``` -![alt text](https://worldofcoding.com/github/images/otland-gitbook/mariadb.png "mariadb") +![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") ###### You are inside the database right now! We will be creating the user 'otadmin' with the password of 'otadminpassword', change these values to what you want it to be! @@ -198,4 +198,4 @@ cmake .. ## Build ```bash make -``` \ No newline at end of file +``` From 355e336c973aa93e35d7817cea4cb74b39afa803 Mon Sep 17 00:00:00 2001 From: Caleb <36135509+Ralumbi@users.noreply.github.com> Date: Sun, 3 May 2020 21:46:48 +0200 Subject: [PATCH 5/7] changed and removed based on pull-request reviews --- .../setup-webserver-linux.md | 37 +++++++++++++------ 1 file changed, 25 insertions(+), 12 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index c434440..920895a 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -24,20 +24,25 @@ Now we will get to the more difficult part of the entire server setup, installin ```bash sudo apt install nginx php-fpm mariadb-server -y ``` -The installation process is now triggered.When this is finished we will install phpmyadmin to handle our database server (which is mariadb) +The installation process is now triggered.When this is finished we will install phpmyadmin to handle our database server ```bash sudo apt install phpmyadmin -y ``` Now we are set to get some configurations going! ## Configuring the webserver + First we want to know which version of php-fpm is installed we will check this by writing the following command in the terminal ```bash sudo php -v ``` -The output will be looking something similar as this (I am using ubuntu 19.10 here which uses php version 7.3 as default. If you're running on a server you most likely run on 18.04 lts or with the newest version 20.04 lts): - -![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") +The output will be looking similar to this: +``` +PHP 7.2.24-0ubuntu0.18.04.3 (cli) (built: Feb 11 2020 15:55:52) ( NTS ) +Copyright (c) 1997-2018 The PHP Group +Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies + with Zend OPcache v7.2.24-0ubuntu0.18.04.3, Copyright (c) 1999-2018, by Zend Technologies +``` Second we want to do is enabling php in our nginx server and setting the configuration just as we want. So we will be going to edit our nginx config. Now we need to install a command line text editor called "vim". After that we installed it we will directly open the configuration file. ```bash @@ -52,7 +57,7 @@ We can change the 'root' directory of the website folder, if you're only using y ## Configuring php -I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which Ubuntu Server version you are running ( and assuming you're using Ubuntu Server 18.04 lts ). +I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which Ubuntu Server version you are running ( and assuming you're using Ubuntu Server 20.04 LTS ). ```bash server { listen 80 default_server; @@ -78,9 +83,9 @@ server { # # # With php-fpm (or other unix sockets): ################## UBUNTU 18.04 LTS ################## - fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + # fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; ################## UBUNTU 20.04 LTS ################## - # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; } @@ -94,7 +99,7 @@ We are set with the entire webserver now and so its time to check if we actually `Change the number of the php-fpm version to one you're using!!!` ```bash sudo systemctl restart nginx -sudo systemctl restart php7.2-fpm +sudo systemctl restart php7.4-fpm ``` Lets open our browser and goto your ip-address and see how wonderful you are! Your very own setup and configured server! @@ -106,7 +111,7 @@ We need to create ourselves a mysql admin account. We will be doing this the fol ```bash sudo mariadb ``` -![alt text](https://worldofcoding.net/github-img/otland-gitbook/phpversion.png "phpversion") + ###### You are inside the database right now! We will be creating the user 'otadmin' with the password of 'otadminpassword', change these values to what you want it to be! @@ -120,6 +125,7 @@ Insert these lines one by one. Now we have setup our database superuser :) ## Configure phpmyadmin + Setup phpmyadmin to access your database via the browser. Insert the following configuration in a new file inside the nginx folder. The following command will create the file and when you are in insert the configuration posted below. @@ -151,9 +157,9 @@ server { include snippets/fastcgi-php.conf; ################## UBUNTU 18.04 LTS ################## - fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + # fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; ################## UBUNTU 20.04 LTS ################## - # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; } @@ -173,29 +179,36 @@ Now we have to enable the phpmyadmin configuration for nginx we do that by runni Finally restart the nginx server with `sudo systemctl restart nginx` and we will be able to access phpmyadmin by http://youripordomain:2344 login with the database username and password we've created. # Setup your Server for TFS + First of all we need to install a few packages to our system which makes us able to build the TFS sources. Directly copy'd from the TFS github wiki(https://github.com/otland/forgottenserver/wiki/Compiling-on-Ubuntu): + ## Install the required software The following command will install Git, CMake, a compiler and the libraries used by The Forgotten Server. Git will be used to download the source code, and CMake will be used to generate the build files. ```bash -sudo apt-get install git cmake build-essential liblua5.2-dev libgmp3-dev libmysqlclient-dev libboost-system-dev libboost-iostreams-dev libboost-filesystem-dev libpugixml-dev libcrypto++-dev +sudo apt install git cmake build-essential libluajit-5.1-dev libmysqlclient-dev libboost-system-dev libboost-iostreams-dev libboost-filesystem-dev libpugixml-dev libcrypto++-dev ``` + ## Download the source code ```bash git clone --recursive https://github.com/otland/forgottenserver.git ``` + ## Generate the build files + ```bash cd forgottenserver mkdir build && cd build cmake .. ``` + ## Build + ```bash make ``` From 6bcb3da1d9ece3343dadd1b8ba4a55dc3a21bd69 Mon Sep 17 00:00:00 2001 From: Caleb <36135509+Ralumbi@users.noreply.github.com> Date: Sun, 3 May 2020 21:49:57 +0200 Subject: [PATCH 6/7] Update setup-webserver-linux.md --- running-your-first-ot-server/setup-webserver-linux.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index 920895a..d475cee 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -57,7 +57,7 @@ We can change the 'root' directory of the website folder, if you're only using y ## Configuring php -I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which Ubuntu Server version you are running ( and assuming you're using Ubuntu Server 20.04 LTS ). +I already enabled php here by writing 'index.php' on line number '24'. I've uncommented the php location settings we need to use. To make it easy and understanding I made own comments for you guys to know which lines to comment and uncomment, depending on which Ubuntu Server version you are running ( and assuming you're using Ubuntu Server 18.04 LTS ). ```bash server { listen 80 default_server; @@ -83,9 +83,9 @@ server { # # # With php-fpm (or other unix sockets): ################## UBUNTU 18.04 LTS ################## - # fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; ################## UBUNTU 20.04 LTS ################## - fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; } @@ -157,9 +157,9 @@ server { include snippets/fastcgi-php.conf; ################## UBUNTU 18.04 LTS ################## - # fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; + fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; ################## UBUNTU 20.04 LTS ################## - fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; + # fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; } From 0da96cfb4676c475a181527a139ad137321d33d0 Mon Sep 17 00:00:00 2001 From: Caleb <36135509+Ralumbi@users.noreply.github.com> Date: Sun, 3 May 2020 21:56:44 +0200 Subject: [PATCH 7/7] Update setup-webserver-linux.md --- running-your-first-ot-server/setup-webserver-linux.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/running-your-first-ot-server/setup-webserver-linux.md b/running-your-first-ot-server/setup-webserver-linux.md index d475cee..97f0529 100644 --- a/running-your-first-ot-server/setup-webserver-linux.md +++ b/running-your-first-ot-server/setup-webserver-linux.md @@ -1,5 +1,5 @@ # Getting started -Rent a Ubuntu Server 18.04 or higher from a trusted hosting company such or install for the sake of learning experience Ubuntu Server 18.04 or higher in VirtualBox. +Rent a Ubuntu Server 18.04 or higher from a trusted hosting company or install for the sake of learning experience Ubuntu Server 18.04 or higher in VirtualBox. Once you're set we will start by accessing our server. If you're on windows you should get putty(https://www.putty.org/), if you're on macOS or Linux you can use the terminal which is standard available. With putty just follow the screen ( insert your domain/ip-address and click ok ) for macOS and linux users type: @@ -49,7 +49,7 @@ Second we want to do is enabling php in our nginx server and setting the configu sudo apt install vim -y && sudo vim /etc/nginx/sites-available/default ``` -Now sit straight up and read carefully on what we're going to do. I am going to give you a few options in the configuration. Underneath here you will find the default configuration file of nginx. ( I only took the part of the config file we are in need to use and left out all the comments which we do use in this tutorial ) +I am going to give you a few options in the configuration. Underneath here you will find the default configuration file of nginx. ( I only took the part of the config file we are in need to use and left out all the comments which we do use in this tutorial ) ## Changing the web-root