Warning |
---|
These sites require python3.6 and git25 to access the repo server. Ensure these two software collection versions are enabled if not just using the configured virtual environment. scl enable rh-python36 bash scl enable sclo-git25 bash |
MAGIC and transplantfirst websites are set up on the renalreg server. Due to historical reasons they are both run under the txfirst
user account on the renalreg server. Both sites follow a similar configuration pattern.
...
Code Block | ||
---|---|---|
| ||
[root@www.renalreg.org ~]# su - txfirst [txfirst@www.renalreg.org ~]$ [txfirst@www.renalreg.org ~]$ ls -l /home/txfirst/sites total 8 drwxr-xr-x. 13 txfirst txfirst 4096 Nov 24 15:24 magic.renalreg.org drwxr-xr-x. 12 txfirst txfirst 4096 Aug 20 14:24 transplantfirst.renalreg.org [txfirst@www.renalreg.org ~]$ |
Django settings are managed differently between the two projects. magic just has a single settings.py file whilst transplantfirst follows the standard of a settings folder with a base.py imported into a local.py and production.py settings file to give the appropriate settings for each environment. In transplantfirst the manage.py file has been edited to default to using the production.py settings file thus avoiding the need for the environment variable DJANGO_MODULE_SETTINGS
to be set. If set it overrides the default.
Warning |
---|
When pulling down magic updates ensure the settings.py file is saved separately as it will be overwritten by the checkout process and lose the production settings. |
The sites are proxied via the software collection apache 2.4 server in /opt/rh/httpd24
with config files in /opt/rh/httpd24/root/etc/httpd/conf.d
with magic configuration in 06-magic.conf
(and 04-transplantfirst.conf
for transplant first). Log files for the proxy server can be found in /var/log/httpd24
and for the sites the log files are currently in the project directory for each project. (These probably should be relocated to /var/log/txfirst and /var/log/magic)
...