adapt docker to demo situation
about predefined token and did
This commit is contained in:
parent
9954b5b603
commit
9b903aafc7
|
@ -31,11 +31,14 @@ IDHUB_ADMIN_USER='admin'
|
||||||
IDHUB_ADMIN_PASSWD='admin'
|
IDHUB_ADMIN_PASSWD='admin'
|
||||||
IDHUB_ADMIN_EMAIL='admin@example.org'
|
IDHUB_ADMIN_EMAIL='admin@example.org'
|
||||||
|
|
||||||
|
IDHUB_SUPPORTED_CREDENTIALS="['CourseCredential', 'EOperatorClaim', 'FederationMembership', 'FinancialVulnerabilityCredential', 'MembershipCard', 'Snapshot']"
|
||||||
|
|
||||||
# this option needs to be set to 'n' to be able to make work idhub in docker
|
# this option needs to be set to 'n' to be able to make work idhub in docker
|
||||||
# by default it is set to 'y' to facilitate idhub dev when outside docker
|
# by default it is set to 'y' to facilitate idhub dev when outside docker
|
||||||
IDHUB_SYNC_ORG_DEV='n'
|
IDHUB_SYNC_ORG_DEV='n'
|
||||||
|
|
||||||
# TODO that is only for testing
|
# TODO that is only for testing/demo purposes
|
||||||
IDHUB_ENABLE_EMAIL=false
|
IDHUB_ENABLE_EMAIL=false
|
||||||
IDHUB_ENABLE_2FACTOR_AUTH=false
|
IDHUB_ENABLE_2FACTOR_AUTH=false
|
||||||
IDHUB_ENABLE_DOMAIN_CHECKER=false
|
IDHUB_ENABLE_DOMAIN_CHECKER=false
|
||||||
|
IDHUB_PREDEFINED_TOKEN='27f944ce-3d58-4f48-b068-e4aa95f97c95'
|
||||||
|
|
|
@ -15,6 +15,7 @@ services:
|
||||||
- ENABLE_EMAIL=${IDHUB_ENABLE_EMAIL:-true}
|
- ENABLE_EMAIL=${IDHUB_ENABLE_EMAIL:-true}
|
||||||
- ENABLE_2FACTOR_AUTH=${IDHUB_ENABLE_2FACTOR_AUTH:-true}
|
- ENABLE_2FACTOR_AUTH=${IDHUB_ENABLE_2FACTOR_AUTH:-true}
|
||||||
- ENABLE_DOMAIN_CHECKER=${IDHUB_ENABLE_DOMAIN_CHECKER:-true}
|
- ENABLE_DOMAIN_CHECKER=${IDHUB_ENABLE_DOMAIN_CHECKER:-true}
|
||||||
|
- PREDEFINED_TOKEN=${IDHUB_PREDEFINED_TOKEN:-}
|
||||||
- SECRET_KEY=${IDHUB_SECRET_KEY:-publicsecretisnotsecureVtmKBfxpVV47PpBCF2Nzz2H6qnbd}
|
- SECRET_KEY=${IDHUB_SECRET_KEY:-publicsecretisnotsecureVtmKBfxpVV47PpBCF2Nzz2H6qnbd}
|
||||||
- STATIC_ROOT=${IDHUB_STATIC_ROOT:-/static/}
|
- STATIC_ROOT=${IDHUB_STATIC_ROOT:-/static/}
|
||||||
- MEDIA_ROOT=${IDHUB_MEDIA_ROOT:-/media/}
|
- MEDIA_ROOT=${IDHUB_MEDIA_ROOT:-/media/}
|
||||||
|
@ -26,7 +27,7 @@ services:
|
||||||
- EMAIL_PORT=${IDHUB_EMAIL_PORT}
|
- EMAIL_PORT=${IDHUB_EMAIL_PORT}
|
||||||
- EMAIL_USE_TLS=${IDHUB_EMAIL_USE_TLS}
|
- EMAIL_USE_TLS=${IDHUB_EMAIL_USE_TLS}
|
||||||
- EMAIL_BACKEND=${IDHUB_EMAIL_BACKEND}
|
- EMAIL_BACKEND=${IDHUB_EMAIL_BACKEND}
|
||||||
- SUPPORTED_CREDENTIALS=['CourseCredential', 'EOperatorClaim', 'FederationMembership', 'FinancialVulnerabilityCredential', 'MembershipCard', 'Snapshot']
|
- SUPPORTED_CREDENTIALS=${IDHUB_SUPPORTED_CREDENTIALS:-}
|
||||||
- SYNC_ORG_DEV=${IDHUB_SYNC_ORG_DEV}
|
- SYNC_ORG_DEV=${IDHUB_SYNC_ORG_DEV}
|
||||||
ports:
|
ports:
|
||||||
- ${IDHUB_PORT:-9001}:${IDHUB_PORT:-9001}
|
- ${IDHUB_PORT:-9001}:${IDHUB_PORT:-9001}
|
||||||
|
|
|
@ -15,6 +15,7 @@ main() {
|
||||||
cp -v .env.example .env
|
cp -v .env.example .env
|
||||||
echo "WARNING: .env was not there, .env.example was copied, this only happens once"
|
echo "WARNING: .env was not there, .env.example was copied, this only happens once"
|
||||||
fi
|
fi
|
||||||
|
. ./.env
|
||||||
|
|
||||||
docker compose down -v
|
docker compose down -v
|
||||||
if [ "${DEV_DOCKER_ALWAYS_BUILD:-}" = 'true' ]; then
|
if [ "${DEV_DOCKER_ALWAYS_BUILD:-}" = 'true' ]; then
|
||||||
|
|
|
@ -45,8 +45,10 @@ deployment_strategy() {
|
||||||
echo "INFO detected NEW deployment"
|
echo "INFO detected NEW deployment"
|
||||||
./manage.py migrate
|
./manage.py migrate
|
||||||
|
|
||||||
printf "This is DEVELOPMENT/PILOTS_EARLY DEPLOYMENT: including demo hardcoded data\n creating initial Datas\n" >&2
|
printf "This is DEVELOPMENT/PILOTS_EARLY DEPLOYMENT: including demo hardcoded data\n" >&2
|
||||||
./manage.py initial_datas
|
|
||||||
|
PREDEFINED_TOKEN="${PREDEFINED_TOKEN:-}"
|
||||||
|
./manage.py demo_data "${PREDEFINED_TOKEN}"
|
||||||
|
|
||||||
if [ "${OIDC_ORGS:-}" ]; then
|
if [ "${OIDC_ORGS:-}" ]; then
|
||||||
config_oidc4vp
|
config_oidc4vp
|
||||||
|
|
Loading…
Reference in a new issue