How to Install Winter CMS with LAMP Stack on Ubuntu 22.04

Winter is a free, open-source content management system based on the Laravel PHP framework. Developers and agencies all around the world rely upon Winter for its quick prototyping and development, safe and secure codebase, and dedication to simplicity. In this article, we are going to learn how to install Winter CMS on Ubuntu 22.04. So, let’s get started.

Checkout the Winter CMS Project Here .

Get started with $5 VPS from CrownCloud. Check our latest offers : CrownCloud VPS [ 24x7 In-House Customer Support ].

Pre-requisites :

  • A system with Ubuntu 22.04 installed and running.

  • root access to the system.

  • LAMP Stack installed and running, for this, you can refer to one of our guides on installing the LAMP Stack (Apache, MariaDB, and PHP).

Once you're all set, we'll proceed with Winter CMS installation and configuration.

Create Database

Let us begin with creating a Database and a user. We will then grant the required privileges to the user so it can interact with the Database.

mysql -u root

CREATE DATABASE ccwintercms;

CREATE USER 'ccwintercms'@'localhost' IDENTIFIED BY 'UYGVc%$#Erfgt*&^%4';

GRANT ALL PRIVILEGES ON ccwintercms.* TO 'ccwintercms'@'localhost';

FLUSH PRIVILEGES;

QUIT

The above commands will give complete access to the user ccwintercms. We would suggest using a strong and long password.

Configuring Apache vHost

Now, create a new Apache configuration file cms.domainhere.info.conf for Winter CMS with the following command.

Replace cms.domainhere.info with the domain name of your own for all the below code examples:

vi /etc/apache2/sites-available/cms.domainhere.info.conf

Now, press i to go to INSERT mode and type in the following lines of codes in the cms.domainhere.info.conf file.

<VirtualHost *:80>

ServerName cms.domainhere.info
ServerAlias cms.domainhere.info
ServerAdmin admin@cms.domainhere.info
DocumentRoot /var/www/html/wintercms

ErrorLog ${APACHE_LOG_DIR}/cms.domainhere.info_error.log
CustomLog ${APACHE_LOG_DIR}/cms.domainhere.info_access.log combined

<Directory /var/www/html/wintercms/>
Options FollowSymlinks
AllowOverride All
Require all granted
</Directory>

</VirtualHost>

Now make directory for Winter CMS files:

mkdir -p /var/www/html/wintercms/

Enable SSL and Rewrite:

a2ensite cms.domainhere.info

a2enmod rewrite ssl

Restart Apache:

systemctl restart apache2

Enable http and https ( 80/443 )

To enable http and https connection through the firewall, follow the commands:

ufw allow 80/tcp

ufw allow 443/tcp

Download Winter CMS

Let's download Winter CMS:

cd /var/www/html/wintercms

wget https://github.com/wintercms/web-installer/releases/latest/download/install.zip

unzip install.zip

chown -R www-data:www-data /var/www/html/wintercms/

chmod -R 775 /var/www/html/wintercms/

Configuring Winter CMS

Now open the domain name with a /install.html from your browser, this will redirect you to configuring the final parts of the Winter CMS installation.

https://cms.domainhere.info/install.html

Replace the cms.domainhere.info with the actual IP or domain configured on the server.

Input the Database details which was configured earlier. Follow the below steps:

Now you have successfully installed Winter CMS with LAMP Stack on Ubuntu 22.04.


CrownCloud - Get a SSD powered KVM VPS at $4.5/month!
Use the code WELCOME for 10% off!

1 GB RAM / 25 GB SSD / 1 CPU Core / 1 TB Bandwidth per month

Available Locations: LAX | MIA | ATL | FRA | AMS