Make use of portal-app-manager.py for Sahana, SeedDMS and Pandora.

This commit is contained in:
Disassembler 2017-09-14 21:56:09 +02:00
parent 35581b9bea
commit 2f2047fb29
4 changed files with 12 additions and 2 deletions

View File

@ -30,9 +30,10 @@ mkdir /srv/sahana/applications/eden/{databases,errors,sessions}
mkdir -p /srv/sahana/applications/eden/static/cache/chart mkdir -p /srv/sahana/applications/eden/static/cache/chart
mkdir -p /srv/sahana/applications/eden/uploads/{gis_cache,images,tracks} mkdir -p /srv/sahana/applications/eden/uploads/{gis_cache,images,tracks}
export SAHANA_HMAC=$(head -c 18 /dev/urandom | base64) export SAHANA_HMAC=$(head -c 18 /dev/urandom | base64)
export SAHANA_ADMIN_PWD=$(head -c 18 /dev/urandom | base64)
envsubst <${SOURCE_DIR}/sahana/srv/sahana/applications/eden/models/000_config.py >/srv/sahana/applications/eden/models/000_config.py envsubst <${SOURCE_DIR}/sahana/srv/sahana/applications/eden/models/000_config.py >/srv/sahana/applications/eden/models/000_config.py
cp ${SOURCE_DIR}/sahana/srv/sahana/applications/eden/modules/templates/default/config.py /srv/sahana/applications/eden/modules/templates/default/config.py cp ${SOURCE_DIR}/sahana/srv/sahana/applications/eden/modules/templates/default/config.py /srv/sahana/applications/eden/modules/templates/default/config.py
export SAHANA_ADMIN_USER=admin@example.com
export SAHANA_ADMIN_PWD=$(head -c 18 /dev/urandom | base64)
envsubst <${SOURCE_DIR}/sahana/srv/sahana/applications/eden/modules/templates/default/users/masterUsers.csv >/srv/sahana/applications/eden/modules/templates/default/users/masterUsers.csv envsubst <${SOURCE_DIR}/sahana/srv/sahana/applications/eden/modules/templates/default/users/masterUsers.csv >/srv/sahana/applications/eden/modules/templates/default/users/masterUsers.csv
cp ${SOURCE_DIR}/sahana/srv/sahana/applications/eden/languages/cz.py /srv/sahana/applications/eden/languages/cz.py cp ${SOURCE_DIR}/sahana/srv/sahana/applications/eden/languages/cz.py /srv/sahana/applications/eden/languages/cz.py
@ -62,6 +63,9 @@ ln -s /etc/nginx/apps-available/sahana /etc/nginx/apps-enabled/sahana
systemctl restart uwsgi systemctl restart uwsgi
systemctl restart nginx systemctl restart nginx
# Add portal application definition
${SOURCE_DIR}/basic/portal-app-manager.py sahana-eden "https://{host}/eden/" "${SAHANA_ADMIN_USER}" "${SAHANA_ADMIN_PWD}"
# TODO: Does matplotlib still require MPLCONFIGDIR directory? # TODO: Does matplotlib still require MPLCONFIGDIR directory?
# If so, /srv/sahana/wsgihandler.py needs to be modified # If so, /srv/sahana/wsgihandler.py needs to be modified

View File

@ -37,5 +37,8 @@ ln -s /etc/nginx/apps-available/seeddms /etc/nginx/apps-enabled/seeddms
systemctl restart php7.0-fpm systemctl restart php7.0-fpm
systemctl restart nginx systemctl restart nginx
# Add portal application definition
${SOURCE_DIR}/basic/portal-app-manager.py seeddms "https://{host}/seeddms/"
# TODO: id3 ssconvers pdftotext catdoc # TODO: id3 ssconvers pdftotext catdoc
# TODO: Test Lucene fulltext search # TODO: Test Lucene fulltext search

View File

@ -65,3 +65,6 @@ for SERVICE in "pandora pandora-tasks pandora-encoding pandora-cron pandora-webs
systemctl start ${SERVICE} systemctl start ${SERVICE}
done done
systemctl restart nginx systemctl restart nginx
# Add portal application definition
${SOURCE_DIR}/basic/portal-app-manager.py pandora "https://{host}:8001/"

View File

@ -1,2 +1,2 @@
First Name,Last Name,Email,Password,Role,Organisation First Name,Last Name,Email,Password,Role,Organisation
Admin,User,admin@example.com,${SAHANA_ADMIN_PWD},ADMIN, Admin,User,${SAHANA_ADMIN_USER},${SAHANA_ADMIN_PWD},ADMIN,

1 First Name Last Name Email Password Role Organisation
2 Admin User admin@example.com ${SAHANA_ADMIN_USER} ${SAHANA_ADMIN_PWD} ADMIN