diff --git a/dockers/mastodon/docker-compose.yml b/dockers/mastodon/docker-compose.yml index eac4be7..d86f6f1 100644 --- a/dockers/mastodon/docker-compose.yml +++ b/dockers/mastodon/docker-compose.yml @@ -13,8 +13,10 @@ services: test: ['CMD', 'pg_isready', '-U', 'postgres'] volumes: - postgres:/var/lib/postgresql/data - environment: - - 'POSTGRES_HOST_AUTH_METHOD=trust' + # environment: + # - 'POSTGRES_HOST_AUTH_METHOD=trust' + env_file: + - ../../secret/env-mastodonDB redis: container_name: ${mastodonRedisName} @@ -72,6 +74,7 @@ services: env_file: - env-config - ../../secret/env-mastodonServ + - ../../secret/env-mastodonDB command: bundle exec puma -C config/puma.rb networks: - mastodonNet diff --git a/dockers/mastodon/env-config b/dockers/mastodon/env-config index 2ff19d9..6255bf1 100644 --- a/dockers/mastodon/env-config +++ b/dockers/mastodon/env-config @@ -24,9 +24,9 @@ REDIS_PORT= # PostgreSQL # ---------- DB_HOST=db -DB_USER=postgres -DB_NAME=postgres -DB_PASS= +#DB_USER=postgres +#DB_NAME=postgres +#DB_PASS= DB_PORT=5432 # Elasticsearch (optional) diff --git a/secret.tmpl/SetAllPass.sh b/secret.tmpl/SetAllPass.sh index 33cdd8f..80f1992 100755 --- a/secret.tmpl/SetAllPass.sh +++ b/secret.tmpl/SetAllPass.sh @@ -349,3 +349,11 @@ peertube_POSTGRES_DB="${peertube_PEERTUBE_DB_NAME}" snappymail_TZ="Europe/Paris" snappymail_UPLOAD_MAX_SIZE="100M" +#################### +# mastodon +mastodon_POSTGRES_USER="--clean_val--" +mastodon_POSTGRES_PASSWORD="--clean_val--" +mastodon_POSTGRES_DB=mastodon +mastodon_DB_USER="${mastodon_POSTGRES_USER}" +mastodon_DB_PASS="${mastodon_POSTGRES_PASSWORD}" +mastodon_DB_NAME=mastodon diff --git a/secret.tmpl/env-mastodonDB b/secret.tmpl/env-mastodonDB new file mode 100644 index 0000000..4c96a89 --- /dev/null +++ b/secret.tmpl/env-mastodonDB @@ -0,0 +1,6 @@ +DB_USER= +DB_NAME= +DB_PASS= +POSTGRES_USER= +POSTGRES_PASSWORD= +POSTGRES_DB=postgres diff --git a/secret.tmpl/env-mastodonServ b/secret.tmpl/env-mastodonServ new file mode 100644 index 0000000..ccaf794 --- /dev/null +++ b/secret.tmpl/env-mastodonServ @@ -0,0 +1,10 @@ +SECRET_KEY_BASE= +OTP_SECRET= +ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY= +ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT= +ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY= +VAPID_PRIVATE_KEY== +VAPID_PUBLIC_KEY= +SMTP_PASSWORD= +EMAIL_DOMAIN_ALLOWLIST= +ADMIN_PASSWORD=