-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🐳 [#4788] Docker compose setup for setup-configuration
add a web-init container and the required scripts for setup_configuration. Example data has been added to docker/data/
- Loading branch information
Showing
6 changed files
with
72 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/bash | ||
|
||
# setup initial configuration using environment variables | ||
# Run this script from the root of the repository | ||
|
||
set -e | ||
|
||
# wait for required services | ||
${SCRIPTPATH}/wait_for_db.sh | ||
|
||
src/manage.py migrate | ||
src/manage.py setup_configuration --no-selftest --yaml-file data/services.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/sh | ||
|
||
set -e | ||
|
||
# Wait for the database container | ||
# See: https://docs.docker.com/compose/startup-order/ | ||
export PGHOST=${DB_HOST:-db} | ||
export PGPORT=${DB_PORT:-5432} | ||
|
||
until pg_isready; do | ||
>&2 echo "Waiting for database connection..." | ||
sleep 1 | ||
done | ||
|
||
>&2 echo "Database is up." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
ZGW_CONSUMERS_CONFIG_ENABLE: True | ||
ZGW_CONSUMERS: | ||
services: | ||
- slug: objecttypen-test | ||
label: Objecttypen API test | ||
api_root: https://httpstat.us/404 | ||
api_type: orc | ||
auth_type: api_key | ||
header_key: Authorization | ||
header_value: Token foo | ||
- slug: objecten-test | ||
label: Objecten API test | ||
api_root: https://httpstat.us/403 | ||
api_type: orc | ||
auth_type: api_key | ||
header_key: Authorization | ||
header_value: Token bar |