Install Coaster CMS on Windows

Contents

Installing PHP and Composer

Installing PHP and Composer is relatively simple, but not entirely obvious for those who haven’t done it before. Here is a good post on installing PHP 7 with Composer on Windows 10.

Once you have completed the steps in the quoted article move on to the next section.

Configuring PHP for Coaster CMS

Coaster CMS requires a few tweaks be made to the php.ini file. The GD2, PDO, Zip and MySQLi extensions are required for Coaster to work correctly.

Installing MySQL Server with Docker

Instead of installing MySQL Server directly onto the host machine, it’s sometimes nice to install this within its own container. This is made possible using Docker. Go ahead and install Docker. If unfamiliar with Docker it can be a bit intimidating at first, but what we aim to do is quite simple. Run the following command from a Powershell or Command Prompt window:

docker run --name mysql -p 3306:3306 -e MYSQL_ROOT_PASSWORD=secret -d mysql:latest

In the above command, we are creating a new MySQL container with the appropriate name “mysql” and forwarding the port 3306 from the container. This allows us to access MySQL from the host machine. The final part of the command, mysql:latest” will download the latest MySQL image from Docker. This is done automatically and won’t require any intervention. The image measures about 400mb, so depending on your connection it could take awhile to download. We are then setting the root MySQL password as “secret”, this can of course be changed to anything you like. The final -d parameter daemonises the container to run in the background.

Accessing the Database

To access the database, we recommend using a program such as HeidiSQL. From here you can create new databases, edit tables, truncate tables and change the structure of tables. Go ahead and create a new table called “coastercms”.

Installing Coaster CMS

Now for the fun part, installing Coaster. Now that we have PHP, Composer and MySQL installed we have everything we need to start a new project. Open a new Powershell window and navigate to a directory you wish to install Coaster. Next run the following command (this may take a while depending on your internet connection):

composer create-project web-feet/coastercms

Thankfully, Laravel has a built-in web server for running projects. Type the following command from within the directory you installed Coaster:

php artisan serve

This will create a web server on the port 8080. Open your web browser, type http://localhost:8080/ and hit return. Hopefully you’ll be greeted with a Coaster CMS install page. At the database section enter 127.0.0.1 as the host, root as the user, your selected password as the password, and coastercms as the database. Feel free to choose your own prefix or leave it blank.

Finally, enter a username, preferably an email address, and a password.

Modern Framework

Based on Laravel 5

Constant development

Additional features always being planned/researched

Open source

"git" involved

Latest from the blog


read more


read more


read more