Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Install Apostrophe on Ubuntu 16.04

In this tutorial, we will explain how to Install Apostrophe CMS on an Ubuntu 16.04 VPS. Apostrophe is an open source, design-driven, in-context CMS built on top of Node.js and MongoDB and it can be used to build both simple and complex content-driven websites. This guide should work on other Linux VPS systems as well but was tested and written for an Ubuntu 16.04 VPS.

Update the system and install necessary packages

Login to your VPS via SSH

ssh user@vps

and run:

sudo apt-get update && sudo apt-get -y upgrade
sudo apt-get install software-properties-common imagemagick build-essential git openssl nano

Install Node.js

The following instructions assume that you don’t have Node.js installed on your machine.

We will install the Node.js version 4 LTS Argon from the nodesource (formerly Chris Lea’s Launchpad PPA) repository.

The command bellow will add the nodesource signing key to your apt keyring, add the deb.nodesource.com repository to your apt sources and run apt-get update to update the package sources.

sudo wget -qO- https://deb.nodesource.com/setup_4.x | sudo bash -

When the command above completes, install the Node.js package with:

sudo apt-get install -y nodejs

To check the Node.js version installed on your machine run:

node --version

The output should be similar to the following:

v4.6.0

Install MongoDB

To install the latest MongoDB package from the official MongoDB repository run the following commands:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv EA312927
echo "deb http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.2 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.2.list
sudo apt-get update
sudo apt-get install mongodb-org
sudo systemctl start mongod

Create your Apostrophe project

To create a new Apostrophe project we will need the tool called apostrophe-cli.

Install the apostrophe-cli globally using the following command:

sudo npm install apostrophe-cli -g

You can now create a new Apostrophe application using the apostrophe cli tool:

apostrophe create myApp

The command above will create a new barebone Apostrophe application in the myApp directory.

Switch to myApp directory and install all the default dependencies using the npm tool with the following commands:

cd myApp
npm install

Once all the dependencies are installed add a new admin user myadmin to the admin group:

node app.js apostrophe-users:add myadmin admin

The above command will prompt you for a password.

Start the application with the following command:

node app.js

You should now have an Apostrophe application running at: http://localhost:3000 or http://YourIpAddress:3000. Open the link in your web browser and you should see something like below:

Hello world!

This is a very barebones Apostrophe project. Now, get to work and make a real website!

That’s it. You have successfully created your first Apostrophe application on your Ubuntu 16.04 machine. For more information about Apostrophe, please refer to the official Apostrophe documentation


PS. If you liked this post please share it with your friends on the social networks using the buttons on the left or simply leave a reply below. Thanks.



This post first appeared on Virtual-Server.org Virtual Server, please read the originial post: here

Share the post

Install Apostrophe on Ubuntu 16.04

×

Subscribe to Virtual-server.org Virtual Server

Get updates delivered right to your inbox!

Thank you for your subscription

×