Mezzo is a Content Management System (CMS) for organizations with complex workflows.
It includes the state-of-the-art of all modern web backend and frontend frameworks and many smart tools for easy development between teams.
- Smart and collaborative content management (Department, Page, News, Events, Media, Project, Job, etc.)
- Full Project data management including project pages, particpants, demo repositories, etc.
- Person activity management per department
- Translation ready models and templates
- Full modular architecture for easy customization including themes
- Full docker packaging for easy scalable deployment on every platform
- Basic CMS
- More complex institutional or corporate web sites with a lot of structural data like departments, persons, projects, etc.
- Any Python and Django based application thanks to the modular architecture
For easier development and production workflow, this application has been fully dockerized.
The Mezzo architecture is designed to be as close as possible with a POSIX OS.
- commands to run the app inside docker containers
- example settings to copy to local_settings.oy before starting anything
- python package dependencies
docker-compose environment files
custom configuration files
default and custom libraries which will be mounted in app container
local application data
- database backup directory
- media uploaded through the app
- postgresql DB (not versioned)
- nginx logs (not versioned)
- uwsgi logs (not versioned)
debian package dependencies
composition file for docker containers used by docker-compose
instructions to build the docker image of the app
Main modules embed in app/organization
- manage events, using _Mezzanine-Agenda
- commons or abstract functionnality
- empty module for easy cutomization
- manage date format
- jobs and candidacies for residency
- all news are managed by topics, articles and briefs
- audio and video gathered in playlist
- create a tree of Organizations > Departments > Teams > Persons
- managing diffent type of pages (admin/pages/page/) and home
- represent projects related to a team or a person
- manage product from prestashop (softwares and subscriptions), using _Cartridge
On MacOS or Windows, you will maybe ned to install Docker-Toolbox and open a Docker Quickstart Terminal.
Then run these commands:
git clone --recursive https://github.com/Ircam-Web/Mezzo.git
Our docker composition already bundles some powerful containers and bleeding edge frameworks like: Nginx, MySQL, Redis, Celery, Django and Python. It thus provides a safe and continuous way to deploy your project from an early development stage to a massive production environment.
For a production environment setup:
Copy the local_settings sample:
cp app/local_settings.py.sample app/local_settings.py
and edit your own local_settings, especially the SECRET_KEY parameter. Then:
which builds, (re)creates, starts, and attaches all containers.
Then browse the app at http://localhost:9051/
On MacOS or Windows, you maybe need to replace 'localhost' by the IP given by the docker terminal.
Before any serious production usecase, you must modify all the passwords and secret keys in the configuration files of the sandbox.
The install the entire composition so that it will be automatically run at boot and in the background:
--uninstall : uninstall the daemon --cron : install cron backup rule (every 6 hours) --user : specify user for cron rule --systemd : use systemd --composition_file : the path of the YAML composition file to use (optional)
This will install a init script in /etc/init.d. For example, if your app directory is named mezzanine-organization then /etc/init.d/mezzanine-organization becomes the init script for the OS booting procedure and for you if you need to start the daemon by hand:
sudo /etc/init.d/mezzo start
For a development environment setup:
This will launch the django development server. Then browse the app at http://localhost:9021/
On MacOS or Windows, we need to replace 'localhost' by the IP given by the docker terminal.
In this mode, Django is run with the runserver tool in DEBUG mode. NEVER use this in production!
If you modify or add django models, you can produce migration files with:
To apply new migrations:
Accessing the app container shell:
docker-compose run app bash
The styles are written in SASS in app/static and the builder uses Gulp. All the builing tools are included in the app container so that you can build the front in one command:
Gulp will launch BrowserSync. BrowserSync is a middleware that expose the website on port 3000. Any change on CSS or JS files will trigger the build system and reload the browser.
- nginx access log of the app
- nginx error log of the app
- uwsgi log of the app
Backup & restore the database
To backup the database and all the media, this will push all of them to the var submodule own repository:
use this ONLY from the production environment!
To restore the backuped the database, all the media and rebuild front ():
use this ONLY from the development environment!
Upgrade application, all dependencies, data from master branch and also recompile assets:
If the app is not accessible, first try to restart the composition with:
If the app is not responding yet, try to restart the docker service and then the app:
docker-compose stop sudo /etc/init.d/docker restart docker-compose up
If the containers are still broken, try to delete exisiting containers (this will NOT delete critical data as database or media):
docker-compose stop docker-compose rm docker-compose up
In case you have installed the init script to run the app as a daemon (cf. section "Daemonize"), you can use it to restart the app:
If you need more informations about running containers:
Or more, inspecting any container of the composition (usefully to know IP of a container):
docker inspect [CONTAINER_ID]
- Copyright (c) 2016-2018 Ircam
- Copyright (c) 2016-2018 Guillaume Pellerin
- Copyright (c) 2016-2018 Emilie Zawadzki
- Copyright (c) 2016-2018 Jérémy Fabre
mezzanine-organization is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
mezzanine-organization is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
Read the LICENSE.txt file for more details.