Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 02/16/2019 in Posts

  1. Hot Cimberly youngfatties
    1 point
  2. Step Four — Configure Nginx to Process PHP Pages Now, we have all of the required components installed. The only configuration change we still need to do is tell Nginx to use our PHP processor for dynamic content. We do this on the server block level (server blocks are similar to Apache's virtual hosts). Open the default Nginx server block configuration file by typing: [iCODE]sudo vi /etc/nginx/conf.d/default.conf[/iCODE] Currently, with the comments removed, the Nginx default server block looks like this: [iCODE]/etc/nginx/conf.d/default.conf — original server { listen 80; server_name localhost; location / { root /usr/share/nginx/html; index index.html index.htm; } error_page 500 502 503 504 /50x.html; location = /50x.html { root /usr/share/nginx/html; } }[/iCODE] We need to make some changes to this file for our site. First, we need to add an index.php option as the first value of our index directive to allow PHP index files to be served when a directory is requested We also need to modify the server_name directive to point to our server's domain name or public IP address The actual configuration file includes some commented out lines that define error processing routines. We will uncomment those to include that functionality For the actual PHP processing, we will need to uncomment a portion of another section. We will also need to add a try_files directive to make sure Nginx doesn't pass bad requests to our PHP processor The changes that you need to make are in red in the text below. If you prefer, you may just copy and paste everything, then replace the value of server_name with the appropriate domain name or IP address: [iCODE]/etc/nginx/conf.d/default.conf — updated server { listen 80; server_name server_domain_name_or_IP; # note that these lines are originally from the "location /" block root /usr/share/nginx/html; index index.php index.html index.htm; location / { try_files $uri $uri/ =404; } error_page 404 /404.html; error_page 500 502 503 504 /50x.html; location = /50x.html { root /usr/share/nginx/html; } location ~ \.php$ { try_files $uri =404; fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }[/iCODE] When you've made the above changes, you can save and close the file. Restart Nginx to make the necessary changes: [iCODE]sudo systemctl restart nginx[/iCODE] Step Five — Test PHP Processing on your Web Server In order to test that our system is configured properly for PHP, we can create a very basic PHP script. We will call this script info.php. In order for Apache to find the file and serve it correctly, it must be saved to a very specific directory, which is called the "web root". In CentOS 7, this directory is located at /usr/share/nginx/html/. We can create the file at that location by typing: [iCODE]sudo vi /usr/share/nginx/html/info.php[/iCODE] This will open a blank file. We want to put the following text, which is valid PHP code, inside the file: [iCODE]Test PHP Script <?php phpinfo(); ?>[/iCODE] When you are finished, save and close the file. Now we can test whether our web server can correctly display content generated by a PHP script. To try this out, we just have to visit this page in our web browser. You'll need your server's public IP address again. The address you want to visit will be: Open in a web browser: [iCODE][Hidden Content]] The page that you come to should look something like this: This page basically gives you information about your server from the perspective of PHP. It is useful for debugging and to ensure that your settings are being applied correctly. If this was successful, then your PHP is working as expected. You probably want to remove this file after this test because it could actually give information about your server to unauthorized users. To do this, you can type this: [iCODE]sudo rm /usr/share/nginx/html/info.php[/iCODE] You can always recreate this page if you need to access the information again later. Conclusion Now that you have a LEMP stack installed, you have many choices for what to do next. Basically, you've installed a platform that will allow you to install most kinds of websites and web software on your server.
    1 point
  3. Umeza Desi College Teen Full Nude Wide Open Legs Pussy Leak
    1 point
  4. Kaira Hot NRI 233 Nude HD Selfie + Leak Video VIDEO LINK: Kaira Hot NRI Nude Leak Video.mp4
    1 point
  5. Yasmin Hot Pakistan Girl In Salwar Nude Selfie Leak
    1 point
  6. Farhana Hot Paki Hijabi Full Nude Selfie
    1 point
  7. 1 point
  8. Zoya Hot Abroad Living Hijab Girl Nude Leak
    1 point
  9. Sana 28 Years Old Bedroom Selfie Hot Body
    1 point
  10. 1 point
  11. Aasma Abroad Living Paki Private Leak
    1 point
  12. Maahi Hot Desi Couple 125 HD Nudes Leak
    1 point
  13. Juhi Hot NRI Girl Some Nude Selfie
    1 point
×
×
  • Create New...
×
GloTorrents Community Forum
Home
Activities
Sign In
Search
More
×