DPP/DLT functionality #36

Merged
pedro merged 68 commits from dpp into main 2024-12-11 15:15:14 +00:00
Showing only changes of commit 3ab21b8c32 - Show all commits

View file

@ -126,6 +126,11 @@ config_phase() {
init_flagfile='/already_configured' init_flagfile='/already_configured'
if [ ! -f "${init_flagfile}" ]; then if [ ! -f "${init_flagfile}" ]; then
# non DL user (only for the inventory)
./manage.py add_institution "${INIT_ORG}"
# TODO: one error on add_user, and you don't add user anymore
./manage.py add_user "${INIT_ORG}" "${INIT_USER}" "${INIT_PASSWD}" "${ADMIN}" "${PREDEFINED_TOKEN}"
if [ "${DPP_MODULE}" = 'y' ]; then if [ "${DPP_MODULE}" = 'y' ]; then
# 12, 13, 14 # 12, 13, 14
config_dpp_part1 config_dpp_part1
@ -135,11 +140,6 @@ config_phase() {
cp example/dpp-snapshots/*.json example/snapshots/ cp example/dpp-snapshots/*.json example/snapshots/
fi fi
# non DL user (only for the inventory)
./manage.py add_institution "${INIT_ORG}"
# TODO: one error on add_user, and you don't add user anymore
./manage.py add_user "${INIT_ORG}" "${INIT_USER}" "${INIT_PASSWD}" "${ADMIN}" "${PREDEFINED_TOKEN}"
# # 15. Add inventory snapshots for user "${INIT_USER}". # # 15. Add inventory snapshots for user "${INIT_USER}".
if [ "${DEMO:-}" = 'true' ]; then if [ "${DEMO:-}" = 'true' ]; then
/usr/bin/time ./manage.py up_snapshots "${INIT_USER}" /usr/bin/time ./manage.py up_snapshots "${INIT_USER}"