some improvements #6

Merged
decentral1se merged 6 commits from make_foodsoft_work_again into main 2022-04-12 10:37:21 +00:00
1 changed files with 62 additions and 144 deletions
Showing only changes of commit 42bdf49ba5 - Show all commits

View File

@ -1,60 +1,68 @@
version: "3.8"
x-env: &env
CERTBOT_DISABLED: 1
DOMAIN:
EMAIL_ERROR:
EMAIL_REPLY_DOMAIN:
EMAIL_SENDER:
FOODCOOP_CITY:
FOODCOOP_COUNTRY:
FOODCOOP_EMAIL:
FOODCOOP_FOOTER:
FOODCOOP_HELP_URL:
FOODCOOP_HOMEPAGE:
FOODCOOP_MULTI_INSTALL:
FOODCOOP_NAME:
FOODCOOP_PHONE:
FOODCOOP_STREET:
FOODCOOP_TIME_ZONE:
FOODCOOP_ZIP_CODE:
FOODCOOP_USE_NICK:
FOODCOOP_LANGUAGE:
LOG_LEVEL:
MYSQL_DB:
MYSQL_HOST:
MYSQL_PORT:
MYSQL_USER:
QUEUE: foodsoft_notifier
REDIS_URL: redis://cache:6379
SECRET_KEY_BASE_FILE: /run/secrets/secret_key_base
SMTP_ADDRESS:
SMTP_AUTHENTICATION:
SMTP_DOMAIN:
SMTP_ENABLE_STARTTLS_AUTO:
SMTP_PASSWORD_FILE: /run/secrets/smtp_password
SMTP_PORT:
SMTP_USER_NAME:
x-configs: &configs
- source: app_config
target: /usr/src/app/config/app_config.yml
- source: db_config
target: /usr/src/app/config/database.yml
- source: production_env
target: /usr/src/app/config/environments/production.rb
- source: entrypoint
target: /usr/src/app/docker-entrypoint.sh
mode: 0555
x-secrets: &secrets
- db_password
- secret_key_base
- smtp_password
services:
yksflip marked this conversation as resolved Outdated

Ah, wait a sec, I think abra can still deal with this it is just the weird !%21merge characters which somehow snuck into the config. I thought I resolved that in c5c0768b10 & 66b6992b0b? Without this admittedly not very nice YAML feature, the duplication of config is really getting too much, no?

Ah, wait a sec, I think `abra` can still deal with this it is just the weird `!%21merge` characters which somehow snuck into the config. I thought I resolved that in https://git.coopcloud.tech/coop-cloud/foodsoft/commit/c5c0768b10a274769c42672b49f45405fb0f72d0 & https://git.coopcloud.tech/coop-cloud/foodsoft/commit/66b6992b0b12fd4b64d686dca8870e07d91b281e? Without this admittedly not very nice YAML feature, the duplication of config is really getting too much, no?

okay, I'll give it another try :)

okay, I'll give it another try :)

nice, my eyes feel releaved!
a simple git fetch could have saved me some pain :D

nice, my eyes feel releaved! a simple git fetch could have saved me some pain :D
app:
image: foodcoops/foodsoft:4.7.1
networks:
- internal
- proxy
secrets:
- db_password
- secret_key_base
- smtp_password
configs:
- source: app_config
target: /usr/src/app/config/app_config.yml
- source: db_config
target: /usr/src/app/config/database.yml
- source: production_env
target: /usr/src/app/config/environments/production.rb
- source: entrypoint
target: /usr/src/app/docker-entrypoint.sh
mode: 0555
secrets: *secrets
configs: *configs
entrypoint: /usr/src/app/docker-entrypoint.sh
environment:
CERTBOT_DISABLED: 1
DOMAIN:
EMAIL_ERROR:
EMAIL_REPLY_DOMAIN:
EMAIL_SENDER:
FOODCOOP_CITY:
FOODCOOP_COUNTRY:
FOODCOOP_EMAIL:
FOODCOOP_FOOTER:
FOODCOOP_HELP_URL:
FOODCOOP_HOMEPAGE:
FOODCOOP_MULTI_INSTALL:
FOODCOOP_NAME:
FOODCOOP_PHONE:
FOODCOOP_STREET:
FOODCOOP_TIME_ZONE:
FOODCOOP_ZIP_CODE:
FOODCOOP_USE_NICK:
FOODCOOP_LANGUAGE:
LOG_LEVEL:
MYSQL_DB:
MYSQL_HOST:
MYSQL_PORT:
MYSQL_USER:
QUEUE: foodsoft_notifier
REDIS_URL: redis://cache:6379
SECRET_KEY_BASE_FILE: /run/secrets/secret_key_base
SMTP_ADDRESS:
SMTP_AUTHENTICATION:
SMTP_DOMAIN:
SMTP_ENABLE_STARTTLS_AUTO:
SMTP_PASSWORD_FILE: /run/secrets/smtp_password
SMTP_PORT:
SMTP_USER_NAME:
<<: *env
FOODSOFT_SERVICE: app
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:3000"]
@ -75,112 +83,22 @@ services:
- coop-cloud.${STACK_NAME}.app.version=4.7.1-
cron:
image: foodcoops/foodsoft:4.7.1
secrets:
- db_password
- secret_key_base
- smtp_password
configs:
- source: app_config
target: /usr/src/app/config/app_config.yml
- source: db_config
target: /usr/src/app/config/database.yml
- source: production_env
target: /usr/src/app/config/environments/production.rb
- source: entrypoint
target: /usr/src/app/docker-entrypoint.sh
mode: 0555
secrets: *secrets
configs: *configs
entrypoint: /usr/src/app/docker-entrypoint.sh
environment:
CERTBOT_DISABLED: 1
DOMAIN:
EMAIL_ERROR:
EMAIL_REPLY_DOMAIN:
EMAIL_SENDER:
FOODCOOP_CITY:
FOODCOOP_COUNTRY:
FOODCOOP_EMAIL:
FOODCOOP_FOOTER:
FOODCOOP_HELP_URL:
FOODCOOP_HOMEPAGE:
FOODCOOP_MULTI_INSTALL:
FOODCOOP_NAME:
FOODCOOP_PHONE:
FOODCOOP_STREET:
FOODCOOP_TIME_ZONE:
FOODCOOP_ZIP_CODE:
FOODCOOP_USE_NICK:
FOODCOOP_LANGUAGE:
LOG_LEVEL:
MYSQL_DB:
MYSQL_HOST:
MYSQL_PORT:
MYSQL_USER:
QUEUE: foodsoft_notifier
REDIS_URL: redis://cache:6379
SECRET_KEY_BASE_FILE: /run/secrets/secret_key_base
SMTP_ADDRESS:
SMTP_AUTHENTICATION:
SMTP_DOMAIN:
SMTP_ENABLE_STARTTLS_AUTO:
SMTP_PASSWORD_FILE: /run/secrets/smtp_password
SMTP_PORT:
SMTP_USER_NAME:
<<: *env
FOODSOFT_SERVICE: cron
networks:
- internal
worker:
image: foodcoops/foodsoft:4.7.1
secrets:
- db_password
- secret_key_base
- smtp_password
configs:
- source: app_config
target: /usr/src/app/config/app_config.yml
- source: db_config
target: /usr/src/app/config/database.yml
- source: production_env
target: /usr/src/app/config/environments/production.rb
- source: entrypoint
target: /usr/src/app/docker-entrypoint.sh
mode: 0555
secrets: *secrets
configs: *configs
entrypoint: /usr/src/app/docker-entrypoint.sh
environment:
CERTBOT_DISABLED: 1
DOMAIN:
EMAIL_ERROR:
EMAIL_REPLY_DOMAIN:
EMAIL_SENDER:
FOODCOOP_CITY:
FOODCOOP_COUNTRY:
FOODCOOP_EMAIL:
FOODCOOP_FOOTER:
FOODCOOP_HELP_URL:
FOODCOOP_HOMEPAGE:
FOODCOOP_MULTI_INSTALL:
FOODCOOP_NAME:
FOODCOOP_PHONE:
FOODCOOP_STREET:
FOODCOOP_TIME_ZONE:
FOODCOOP_ZIP_CODE:
FOODCOOP_USE_NICK:
FOODCOOP_LANGUAGE:
LOG_LEVEL:
MYSQL_DB:
MYSQL_HOST:
MYSQL_PORT:
MYSQL_USER:
QUEUE: foodsoft_notifier
REDIS_URL: redis://cache:6379
SECRET_KEY_BASE_FILE: /run/secrets/secret_key_base
SMTP_ADDRESS:
SMTP_AUTHENTICATION:
SMTP_DOMAIN:
SMTP_ENABLE_STARTTLS_AUTO:
SMTP_PASSWORD_FILE: /run/secrets/smtp_password
SMTP_PORT:
SMTP_USER_NAME:
<<: *env
FOODSOFT_SERVICE: worker
networks:
- internal