aboutsummaryrefslogtreecommitdiffstats
path: root/docs/source/siteadmin/deploying.rst
diff options
context:
space:
mode:
Diffstat (limited to 'docs/source/siteadmin/deploying.rst')
-rw-r--r--docs/source/siteadmin/deploying.rst60
1 files changed, 34 insertions, 26 deletions
diff --git a/docs/source/siteadmin/deploying.rst b/docs/source/siteadmin/deploying.rst
index 47901da9..42fe1772 100644
--- a/docs/source/siteadmin/deploying.rst
+++ b/docs/source/siteadmin/deploying.rst
@@ -25,7 +25,7 @@ will take you step-by-step through setting up your own instance of MediaGoblin.
Of course, when it comes to setting up web applications like MediaGoblin,
there's an almost infinite way to deploy things, so for now, we'll keep it
simple with some assumptions. We recommend a setup that combines MediaGoblin +
-virtualenv + fastcgi + nginx on a .deb- or .rpm-based GNU/Linux distro.
+virtualenv + FastCGI + Nginx on a .deb- or .rpm-based GNU/Linux distro.
Other deployment options (e.g., deploying on FreeBSD, Arch Linux, using
Apache, etc.) are possible, though! If you'd prefer a different deployment
@@ -65,25 +65,30 @@ MediaGoblin has the following core dependencies:
- `virtualenv <http://www.virtualenv.org/>`_
- `nodejs <https://nodejs.org>`_
-On a DEB-based system (e.g Debian, gNewSense, Trisquel, *buntu, and
+On a DEB-based system (e.g Debian, gNewSense, Trisquel, \*buntu, and
derivatives) issue the following command::
sudo apt-get install git-core python python-dev python-lxml \
python-imaging python-virtualenv npm nodejs-legacy automake \
- nginx
+ nginx rabbitmq-server
On a RPM-based system (e.g. Fedora, RedHat, and derivatives) issue the
following command::
sudo yum install python-paste-deploy python-paste-script \
git-core python python-devel python-lxml python-imaging \
- python-virtualenv npm automake nginx
+ python-virtualenv npm automake nginx rabbitmq-server
(Note: MediaGoblin now officially supports Python 3. You may instead
substitute from "python" to "python3" for most package names in the
Debian instructions and this should cover dependency installation.
These instructions have not yet been tested on Fedora.)
+(Note: you might have to include additional repositories to a RPM-
+based system, because rabbitmq-server might be not included in
+official repositories. As an alternative, you can try installing
+redis-server and configure it as celery broker)
+
Configure PostgreSQL
~~~~~~~~~~~~~~~~~~~~
@@ -94,7 +99,7 @@ Configure PostgreSQL
For medium to large deployments we recommend PostgreSQL.
- If you don't want/need postgres, skip this section.
+ If you don't want/need PostgreSQL, skip this section.
These are the packages needed for Debian Jessie (stable)::
@@ -105,7 +110,7 @@ These are the packages needed for an RPM-based system::
sudo yum install postgresql postgresql-server python-psycopg2
An rpm-based system also requires that you initialize and start the
-PostgresSQL database with a few commands. The following commands are
+PostgreSQL database with a few commands. The following commands are
not needed on a Debian-based platform, however::
sudo /usr/bin/postgresql-setup initdb
@@ -113,8 +118,8 @@ not needed on a Debian-based platform, however::
sudo systemctl start postgresql
The installation process will create a new *system* user named ``postgres``,
-which will have privilegies sufficient to manage the database. We will create a
-new database user with restricted privilegies and a new database owned by our
+which will have privileges sufficient to manage the database. We will create a
+new database user with restricted privileges and a new database owned by our
restricted database user for our MediaGoblin instance.
In this example, the database user will be ``mediagoblin`` and the database
@@ -200,10 +205,10 @@ Create a MediaGoblin Directory
You should create a working directory for MediaGoblin. This document
assumes your local git repository will be located at
``/srv/mediagoblin.example.org/mediagoblin/``.
-Substitute your prefered local deployment path as needed.
+Substitute your preferred local deployment path as needed.
Setting up the working directory requires that we first create the directory
-with elevated priviledges, and then assign ownership of the directory
+with elevated privileges, and then assign ownership of the directory
to the unprivileged system account.
To do this, enter the following command, changing the defaults to suit your
@@ -235,7 +240,7 @@ Change to the MediaGoblin directory that you just created::
Clone the MediaGoblin repository and set up the git submodules::
- $ git clone git://git.savannah.gnu.org/mediagoblin.git -b stable
+ $ git clone https://git.savannah.gnu.org/git/mediagoblin.git -b stable
$ cd mediagoblin
$ git submodule init && git submodule update
@@ -245,7 +250,7 @@ Clone the MediaGoblin repository and set up the git submodules::
gitorious.org shut down, we had to move. We are presently on
Savannah. You may need to update your git repository location::
- $ git remote set-url origin git://git.savannah.gnu.org/mediagoblin.git
+ $ git remote set-url origin https://git.savannah.gnu.org/git/mediagoblin.git
Set up the hacking environment::
@@ -314,25 +319,28 @@ Edit site configuration
~~~~~~~~~~~~~~~~~~~~~~~
A few basic properties must be set before MediaGoblin will work. First
-make a copy of ``mediagoblin.ini`` and ``paste.ini`` for editing so the original
+make a copy of ``paste.ini`` for editing so the original
config files aren't lost (you likely won't need to edit the paste configuration,
but we'll make a local copy of it just in case)::
- $ cp -av mediagoblin.ini mediagoblin_local.ini && cp -av paste.ini paste_local.ini
+ $ cp -av paste.ini paste_local.ini
+
+``mediagoblin.ini`` does not need to be copied, because original config is
+stored in ``mediagoblin.example.ini``.
-Then edit mediagoblin_local.ini:
+Then edit ``mediagoblin.ini``:
- Set ``email_sender_address`` to the address you wish to be used as
the sender for system-generated emails
- Edit ``direct_remote_path``, ``base_dir``, and ``base_url`` if
your mediagoblin directory is not the root directory of your
- vhost.
+ site.
Configure MediaGoblin to use the PostgreSQL database
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-If you are using postgres, edit the ``[mediagoblin]`` section in your
-``mediagoblin_local.ini`` and put in::
+If you are using PostgreSQL, edit the ``[mediagoblin]`` section in your
+``mediagoblin.ini`` and put in::
sql_engine = postgresql:///mediagoblin
@@ -361,7 +369,7 @@ test the deployment with the following command::
You should be able to connect to the machine on port 6543 in your
browser to confirm that the service is operable.
-The next series of commands will need to be run as a priviledged user. Type
+The next series of commands will need to be run as a privileged user. Type
exit to return to the root/sudo account.::
exit
@@ -372,9 +380,9 @@ exit to return to the root/sudo account.::
FastCGI and nginx
~~~~~~~~~~~~~~~~~
-This configuration example will use nginx, however, you may
+This configuration example will use Nginx, however, you may
use any webserver of your choice as long as it supports the FastCGI
-protocol. If you do not already have a web server, consider nginx, as
+protocol. If you do not already have a web server, consider Nginx, as
the configuration files may be more clear than the
alternatives.
@@ -397,7 +405,7 @@ following commands::
sudo systemctl enable nginx
You can modify these commands and locations depending on your preferences and
-the existing configuration of your nginx instance. The contents of
+the existing configuration of your Nginx instance. The contents of
this ``nginx.conf`` file should be modeled on the following::
server {
@@ -457,7 +465,7 @@ this ``nginx.conf`` file should be modeled on the following::
fastcgi_pass 127.0.0.1:26543;
include /etc/nginx/fastcgi_params;
- # our understanding vs nginx's handling of script_name vs
+ # our understanding vs Nginx's handling of script_name vs
# path_info don't match :)
fastcgi_param PATH_INFO $fastcgi_script_name;
fastcgi_param SCRIPT_NAME "";
@@ -481,8 +489,8 @@ test to ensure that this configuration works::
nginx -t
-If you encounter any errors, review your nginx configuration files, and try to
-resolve them. If you do not encounter any errors, you can start your nginx
+If you encounter any errors, review your Nginx configuration files, and try to
+resolve them. If you do not encounter any errors, you can start your Nginx
server with one of the following commands (depending on your environment)::
sudo /etc/init.d/nginx restart
@@ -529,7 +537,7 @@ a) Disable registration on your instance and just make
[mediagoblin]
allow_registration = false
-b) Enable a captcha plugin. But unfortunately, though some captcha
+b) Enable a CAPTCHA plugin. But unfortunately, though some CAPTCHA
plugins exist, for various reasons we do not have any general
recommendations we can make at this point.