How to Install WonderCMS on Ubuntu 18.04 LTS
source link: https://www.vultr.com/docs/how-to-install-wondercms-on-ubuntu-18-04-lts
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Using a Different System?
WonderCMS is an open source, fast and small flat file CMS written in PHP. WonderCMS source code is hosted on Github. This guide will show you how to install WonderCMS on a fresh Ubuntu 18.04 LTS Vultr instance with Nginx as a web server.
Requirements
- PHP version 7.1 or greater with the
curl
,mbstring
andzip
extensions. - Web server, such as Apache with
mod_rewrite
module enabled, Nginx or IIS. This guide will use Nginx.
Before you begin
Check the Ubuntu version.
lsb_release -ds
# Ubuntu 18.04.1 LTS
Create a new non-root
user account with sudo
access and switch to it.
adduser johndoe --gecos "John Doe"
usermod -aG sudo johndoe
su - johndoe
NOTE: Replace johndoe
with your username.
Set up the timezone.
sudo dpkg-reconfigure tzdata
Ensure that your system is up to date.
sudo apt update && sudo apt upgrade -y
Install necessary packages.
sudo apt install -y zip unzip curl wget git
Install PHP
Install PHP, as well as the necessary PHP extensions.
sudo apt install -y php7.2 php7.2-cli php7.2-fpm php7.2-common php7.2-curl php7.2-zip php7.2-mbstring
Check the version.
php --version
# PHP 7.2.15-0ubuntu0.18.04.1 (cli) (built: Feb 8 2019 14:54:22) ( NTS )
Install Nginx
Install Nginx.
sudo apt install -y nginx
Check the version.
sudo nginx -v
# nginx version: nginx/1.14.0 (Ubuntu)
Run sudo vim /etc/nginx/sites-available/wondercms.conf
and configure Nginx for WonderCMS.
server {
listen 80;
server_name example.com;
root /var/www/wondercms;
index index.php;
location / {
if (!-e $request_filename) {
rewrite ^/(.+)$ /index.php?page=$1 last;
}
}
location ~ database.js {
return 403;
}
location ~ \.php(/|$) {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.2-fpm.sock;
}
}
Save the file and exit.
Activate the new wondercms.conf
configuration by linking the file to the sites-enabled
directory.
sudo ln -s /etc/nginx/sites-available/wondercms.conf /etc/nginx/sites-enabled/
Test the configuration.
sudo nginx -t
Reload Nginx.
sudo systemctl reload nginx.service
Install WonderCMS
Create a document root directory.
sudo mkdir -p /var/www/wondercms
Change ownership of the /var/www/wondercms
directory to johndoe
.
sudo chown -R johndoe:johndoe /var/www/wondercms
Navigate to the document root folder.
cd /var/www/wondercms
Download and unzip WonderCMS.
wget https://github.com/robiso/wondercms/releases/download/2.6.0/WonderCMS-2.6.0.zip
unzip WonderCMS-2.6.0.zip
rm WonderCMS-2.6.0.zip
Move WonderCMS files to the document root directory.
mv wondercms/* . && mv wondercms/.* .
rmdir wondercms
Change ownership of the /var/www/wondercms
directory to www-data
.
sudo chown -R www-data:www-data /var/www/wondercms
Open your site in a web browser and log in with the default password admin
and change the default password afterward.
Want to contribute?
You could earn up to $600 by adding new articles
Recommend
-
12
Install Ubuntu Server 20.04.1 LTS 64-bit on Raspberry Pi I was trying to get Ubuntu Server 20.04.1 LTS Focal Fossa installed on a Raspberry Pi 3 B+. While this seems like it should have been a straig...
-
10
Install Asterisk 18 LTS on Ubuntu 20.04|18.04Search ComputingForGeeksAsterisk is a free and open source fram...
-
10
Install and Use Percona Toolkit on Ubuntu 20.04/18.04 LTSSearch ComputingForGeeksIn this blog post, we will...
-
9
Install Dolibarr ERP & CRM on Ubuntu 18.04 LTSSearch ComputingForGeeksThis guide will cover how to insta...
-
12
Install Elasticsearch 6.x on Ubuntu 18.04 LTS (Bionic Beaver) LinuxSearch ComputingForGeeksThis guide will h...
-
5
How To Install NetBox on Ubuntu 18.04 LTSSearch ComputingForGeeksHow to Install NetBox on Ubuntu 18.04 LTS i...
-
3
Using a Different System?
-
6
Using a Different System?
-
1
Using a Different System?
-
3
Using a Different System?
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK