{"id":17436,"date":"2015-07-08T23:05:59","date_gmt":"2015-07-09T04:05:59","guid":{"rendered":"https:\/\/secure.rosehosting.com\/blog\/?p=17436"},"modified":"2022-06-03T03:44:17","modified_gmt":"2022-06-03T08:44:17","slug":"install-mezzanine-cms-on-a-debian-vps","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/install-mezzanine-cms-on-a-debian-vps\/","title":{"rendered":"Install Mezzanine CMS on a Debian VPS"},"content":{"rendered":"
In this blog post we will show you how to install the Mezzanine CMS on a Debian 8 VPS<\/a>. Mezzanine is open source content management system built using the Django framework. Some of the main features include: Blog engine, Shopping cart module, User accounts and profiles, In-line page editing ..etc.<\/p>\n <\/p>\n To install MariaDB, run the following commands:<\/p>\n When the installation is complete, run the following command to secure your installation:<\/p>\n Next, we need to create a database for our mezzanine installation.<\/p>\n Open the file Initialize the database:<\/p>\n The script will ask you to create a superuser and a few other questions.<\/p>\n When the initialization is finished, run the following command to start the Mezzanine:<\/p>\n If you see the following <\/span>message, it means you’ve successfully installed Mezzanine.<\/p>\n That’s it. You have successfully installed Mezzanine. The application should be available at http:\/\/your_server_ip:8000\/ or http:\/\/localhost:8000\/<\/p>\n For more info about the Mezzanine CMS please go to: http:\/\/mezzanine.jupo.org\/<\/p>\n Of course you don\u2019t have to do any of this if you use one of our Linux VPS Hosting<\/a> services, in which case you can simply ask our expert Linux admins to install this for you. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n PS<\/strong>.<\/span> 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.<\/p>\n","protected":false},"excerpt":{"rendered":" In this blog post we will show you how to install the Mezzanine CMS on a Debian 8 VPS. Mezzanine … <\/p>\nLogin to your VPS via SSH<\/h4>\n
ssh user@vps<\/pre>\n
Update the system and install necessary packages.<\/h4>\n
[user]$ sudo apt-get update && sudo apt-get -y upgrade\r\n[user]$ sudo apt-get install python-software-properties build-essential python python-dev libjpeg62-turbo-dev libssl-dev<\/pre>\n
Install MariaDB 10.0 and create a database<\/h4>\n
[user]$ sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xcbcb082a1bb943db\r\n[user]$ sudo add-apt-repository 'deb http:\/\/mirror.jmu.edu\/pub\/mariadb\/repo\/10.0\/debian jessie main'\r\n[user]$ sudo apt-get update\r\n[user]$ sudo apt-get install -y mariadb-server libmariadbclient-dev<\/pre>\n
[user]$ mysql_secure_installation<\/pre>\n
[user]$ mysql -uroot -p\r\nMariaDB [(none)]> CREATE DATABASE mezzanine;\r\nMariaDB [(none)]> GRANT ALL PRIVILEGES ON mezzanine.* TO 'mezzanineuser'@'localhost' IDENTIFIED BY 'mezzanineuser_passwd';\r\nMariaDB [(none)]> FLUSH PRIVILEGES;\r\nMariaDB [(none)]> \\q<\/pre>\n
Install pip and a python virtual environment<\/span><\/h4>\n
[user]$ sudo apt-get install python-pip<\/pre>\n
[user]$ sudo pip install --upgrade virtualenv\r\n[user]$ mkdir -p ~\/.virtualenvs\/mezzanine\r\n[user]$ virtualenv ~\/.virtualenvs\/mezzanine\r\n[user]$ source ~\/.virtualenvs\/mezzanine\/bin\/activate<\/pre>\n
Install Mezzanine and create a new project<\/h4>\n
(mezzanine)$ pip install mezzanine<\/pre>\n
(mezzanine)$ mezzanine-project my_mezzanine\r\n(mezzanine)$ cd ~\/my_mezzanine<\/pre>\n
local_settings.py<\/code> and edit the database configuration values:<\/p>\n
(mezzanine)$ nano local_settings.py<\/pre>\n
DATABASES = {\r\n \"default\": {\r\n # Ends with \"postgresql_psycopg2\", \"mysql\", \"sqlite3\" or \"oracle\".\r\n \"ENGINE\": \"django.db.backends.mysql\",\r\n # DB name or path to database file if using sqlite3.\r\n \"NAME\": \"mezzanine\",\r\n # Not used with sqlite3.\r\n \"USER\": \"mezzanineuser\",\r\n # Not used with sqlite3.\r\n \"PASSWORD\": \"mezzanineuser_passwd\",\r\n # Set to empty string for localhost. Not used with sqlite3.\r\n \"HOST\": \"\",\r\n # Set to empty string for default. Not used with sqlite3.\r\n \"PORT\": \"\",\r\n }\r\n}\r\n<\/pre>\n
(mezzanine)$ python manage.py createdb<\/pre>\n
(mezzanine)$ python manage.py runserver 0.0.0.0:8000<\/pre>\n
Validating models...\r\n\r\n0 errors found\r\nJuly 08, 2015 - 13:45:18\r\nDjango version 1.6.11, using se.settings'\r\nStarting development server at http:\/\/0.0.0.0:8000\/\r\nQuit the server with CONTROL-C.\r\n<\/pre>\n
\n