{"id":4047,"date":"2019-08-20T23:15:39","date_gmt":"2019-08-20T20:15:39","guid":{"rendered":"https:\/\/kifarunix.com\/?p=4047"},"modified":"2019-08-24T09:57:48","modified_gmt":"2019-08-24T06:57:48","slug":"install-wondercms-with-nginx-on-debian-10","status":"publish","type":"post","link":"https:\/\/kifarunix.com\/install-wondercms-with-nginx-on-debian-10\/","title":{"rendered":"Install WonderCMS with Nginx on Debian 10"},"content":{"rendered":"\n
In our previous guide, we discussed how to install WonderCMS<\/a> on Debian 10 Buster which uses Apache as the webserver. In this guide, we will learn how to install WonderCMS with Nginx on Debian 10 Buster.<\/p>\n\n\n\n If you want to check our previous guide on installing WonderCMS with Apache, follow the link below;<\/p>\n\n\n\n Install WonderCMS on Debian 10 Buster<\/a><\/p>\n\n\n\n There are a number of requirements that WonderCMS requires. These include;<\/p>\n\n\n\n To begin with, update and upgrade your system packages.<\/p>\n\n\n\n Install Nginx Web server, PHP and the required extensions. PHP 7.3 is the default available version on Debian 10 Buster.<\/p>\n\n\n\n Apache installs by default with PHP. Hence, stop it and run Nginx.<\/p>\n\n\n\n Start and enable Nginx to run on boot.<\/p>\n\n\n\n Create WonderCMS Nginx configuration file with the following content.<\/p>\n\n\n\n Run Nginx configuration test.<\/p>\n\n\n\n Enable WonderCMS Nginx site.<\/p>\n\n\n\n Reload Nginx service to effect the changes<\/p>\n\n\n\n Download WonderCMS zipped configuration and extract them to the WonderCMS Nginx root web directory.<\/p>\n\n\n\n Change the user and group ownership of WonderCMS configuration to web server user.<\/p>\n\n\n\n Restart Nginx<\/p>\n\n\n\n You can now access WonderCMS via the address, http:\/\/wondercms.example.com<\/a>.<\/p>\n\n\n\n Click on \u201cClick to login<\/strong>\u201d to login to your site using the provided password.<\/p>\n\n\n\n Change the default password by navigating to Settings > Security<\/strong>.<\/p>\n\n\n\n You have successfully installed WonderCMS with Nginx on Debian 10 Buster.<\/p>\n\n\n\n From WonderCMS, here are five safety recommended tips.<\/p>\n\n\n\n Read more about WonderCMS on WonderCMS wiki<\/a>.<\/p>\n\n\n\n Install Automad CMS on Debian 10\/Ubuntu 18.04<\/a><\/p>\n\n\n\n Install Snipe-IT on Debian 10\/Ubuntu 18.04<\/a><\/p>\n\n\n\nInstall WonderCMS with Nginx on Debian 10<\/h2>\n\n\n\n
Prerequisites<\/h3>\n\n\n\n
Install WonderCMS Requirements<\/h4>\n\n\n\n
apt update\napt upgrade<\/code><\/pre>\n\n\n\n
apt install nginx php php-fpm php-mbstring php-curl php-zip<\/code><\/pre>\n\n\n\n
Running Nginx<\/h3>\n\n\n\n
systemctl stop apache2\nsystemctl disable apache2\nsystemctl mask apache2<\/code><\/pre>\n\n\n\n
systemctl start nginx\nsystemctl enable nginx<\/code><\/pre>\n\n\n\n
Configure Nginx for WonderCMS<\/h3>\n\n\n\n
vim \/etc\/nginx\/sites-available\/wondercms.conf<\/code><\/pre>\n\n\n\n
server {\n listen 80;\n server_name wondercms.example.com;\n root \/usr\/share\/nginx\/html\/wondercms;\n index index.php;\n autoindex off;\n\n location \/ {\n if (!-e $request_filename) {\n rewrite ^\/(.+)$ \/index.php?page=$1 last;\n }\n }\n\n # prevent access to database.js\n location ~ database.js {\n return 403;\n }\n\n location ~ \\.php(\/|$) {\n include fastcgi.conf;\n fastcgi_pass unix:\/run\/php\/php7.3-fpm.sock;\n }\n}<\/code><\/pre>\n\n\n\n
nginx -t<\/code><\/pre>\n\n\n\n
ln -s \/etc\/nginx\/sites-available\/wondercms.conf \/etc\/nginx\/sites-enabled\/<\/code><\/pre>\n\n\n\n
systemctl restart nginx<\/code><\/pre>\n\n\n\n
Install WonderCMS on Debian 10 Buster<\/h3>\n\n\n\n
git clone https:\/\/github.com\/robiso\/wondercms.git \/var\/www\/html\/wondercms<\/code><\/pre>\n\n\n\n
chown -R www-data:www-data \/var\/www\/html\/wondercms<\/code><\/pre>\n\n\n\n
systemctl restart nginx<\/code><\/pre>\n\n\n\n
Accessing WonderCMS<\/h3>\n\n\n\n
<\/a><\/figure>\n\n\n\n
<\/a><\/figure>\n\n\n\n
<\/a><\/figure>\n\n\n\n
More Tutorials<\/h4>\n\n\n\n