Changes between Version 1 and Version 2 of ProductieStappen


Ignore:
Timestamp:
01/14/15 11:36:41 (10 years ago)
Author:
mschenk
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • ProductieStappen

    v1 v2  
    11[[PageOutline]]
    22
    3 = Mysql =
     3[[Image(Extension-School.png,100%)]]
    44
    5 == Master ==
     5These are the systems involved in the website:
    66
    7 De master database moet geconfigureerd zijn als master (met voldoende log-file retention)
     7= dex-db1 =
    88
    9 [[InterTrac]]
     9This physical machine holds the master database-server
    1010
    11 == Slave ==
     11== MySQL master ==
    1212
    13 De slaves moeten geconfigureerd worden d.m.v. het script [sys:source:dex-app1]
    1413
    15 [[IncludeSource(branches/versie-1.3/migrate/migration/management/commands/fullmigration.py,start=180,end=201)]]
     14The master database is installed directly on dex-db1. Configuration is done by the ICT department's database support.
    1615
    17 = Django applicatie =
     16
     17= dex-app1 =
     18
     19This physical machine runs the front-end webserver, one application server, and a slave-database server. All these component are run from docker.
     20
     21Full docker-configurations (using fig) can be found here: [source:services/trunk/production/dex-app1]
     22
     23== MySQL-Slave ==
     24
     25MySQL-Slave provides a read-only database on each application server. This database is only present for performance reasons.
     26
     27Slave mysql-servers are run as docker instances.
     28
     29Slaves need to be configured for first time use using the script [source:services/trunk/production/dex-app1/mysql/etc/initialcopy.sh]. This script is available from within the docker instance through /etc/mysql/initialcopy.sh
     30
     31Input for this script is the hostname for the master-server, and passwords for an admin user to retrieve the full database from the master and a replication user to replicate the database.
     32
     33[[IncludeSource(services/trunk/production/dex-app1/mysql/etc/initialcopy.sh,start=3,end=8)]]
     34
     35The script [source:services/trunk/production/dex-app1/mysql/etc/renewcopy.sh] does almost the same as initialcopy, it only uses authentication  in a different fashion. This script can be used when a slave-database has lost synchronization with the master for whatever reason.
     36
     37== NGINX ==
     38
     39Nginx provides a web-server that is used to serve static content and forward requests to the uwsgi servers running the actual website application
     40
     41Full nginx configuration can be found in [source:services/trunk/production/dex-app1/nginx]
     42
     43== UWSGI ==
     44
     45This container runs the actual website code. The current website code needs to be installed in /var/o2eappserver/fig/website. This directory is available as /code inside the docker image. (Further paths in this section will be specific to the docker instance)
     46
     47The website as checked out from svn will not work properly due to missing settings. In order to create a working setup a settings_local.py file needs to be installed in /code/website/conf
     48
     49=== Migration ===
     50
     51When migration's are run (using Django south) the system will mess up in a master-slave configuration. This is due to bugs in the south multi-db implementation. In order to circumvent these problems
     52