7. Deployment

7.1. Install via yum

$ yum install pdc-server

The RPM includes a cron job to perform daily synchronization of users with LDAP. It is installed to /etc/cron.daily and does not need any configuration.

7.2. Configure Django settings

# mv settings_local.py.dist to settings_local.py
# change database settings in /usr/lib/pythonX.Y/site-packages/pdc/settings_local.py

7.3. Initialize database

# create database
$ su - postgres
$ psql
postgres=# create database "db_name" owner "user_name";
postgres=# \q

# migrate database
$ django-admin migrate --settings=pdc.settings --noinput

7.4. Collect static

$ django-admin collectstatic --settings=pdc.settings

7.5. Config apache

replace PDC_HOSTNAME with server’s hostname in /etc/httpd/conf.d/pdc.conf