diff options
| -rw-r--r-- | README.md | 2 | ||||
| -rw-r--r-- | alembic/README | 2 | ||||
| -rw-r--r-- | alembic/versions/4d293b37634c_initial_migration.py | 2 | ||||
| -rw-r--r-- | docker-compose.yml | 24 | ||||
| -rw-r--r-- | entry_point.sh | 2 | 
5 files changed, 14 insertions, 18 deletions
| @@ -18,4 +18,4 @@ If you alter the models then use `poetry run alembic revision -m "<What you chan  ### Join us on Discord! -If you are a Python programmer and want to meet fellow Pythonistas, come join us at <https://discord.gg/python>!  +If you are a Python programmer and want to meet fellow Pythonistas, come join us at <https://discord.gg/python>! diff --git a/alembic/README b/alembic/README index 98e4f9c..2500aa1 100644 --- a/alembic/README +++ b/alembic/README @@ -1 +1 @@ -Generic single-database configuration.
\ No newline at end of file +Generic single-database configuration. diff --git a/alembic/versions/4d293b37634c_initial_migration.py b/alembic/versions/4d293b37634c_initial_migration.py index 23e7ea4..fa5e21b 100644 --- a/alembic/versions/4d293b37634c_initial_migration.py +++ b/alembic/versions/4d293b37634c_initial_migration.py @@ -1,7 +1,7 @@  """initial migration  Revision ID: 4d293b37634c -Revises:  +Revises:  Create Date: 2020-08-25 03:09:13.565389  """ diff --git a/docker-compose.yml b/docker-compose.yml index 84420a7..0d5bf14 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,26 +1,22 @@  version: "3.8"  x-logging: &logging -  logging: -    driver: "json-file" -    options: -      max-file: "5" -      max-size: "10m" - -x-restart-policy: &restart_policy -  restart: "no" +  driver: "json-file" +  options: +    max-file: "5" +    max-size: "10m"  services:    postgres: -    << : *logging -    << : *restart_policy +    logging: *logging      image: postgres:13-alpine +    restart: "no"      environment:        POSTGRES_DB: pysite        POSTGRES_PASSWORD: pysite        POSTGRES_USER: pysite      healthcheck: -      test: ["CMD-SHELL", "pg_isready -U pysite"] +      test: [ "CMD-SHELL", "pg_isready -U pysite" ]        interval: 2s        timeout: 1s        retries: 5 @@ -28,9 +24,9 @@ services:        - 5432:5432    metricity: -    << : *logging -    << : *restart_policy -    depends_on:  +    logging: *logging +    restart: "no" +    depends_on:        postgres:          condition: service_healthy      build: diff --git a/entry_point.sh b/entry_point.sh index 3894eff..4eb5beb 100644 --- a/entry_point.sh +++ b/entry_point.sh @@ -4,7 +4,7 @@ poetry run python create_metricity_db.py  poetry run alembic upgrade head  if [ -e /tmp/bot/metricity-config.toml ]; then -    echo "Detected metricity running in bot context, copying config."  +    echo "Detected metricity running in bot context, copying config."      cp --force /tmp/bot/metricity-config.toml ./config.toml  fi | 
