diff options
author | Leopere <1068374+Leopere@users.noreply.github.com> | 2019-11-18 03:38:05 -0500 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-11-18 09:38:05 +0100 |
commit | e2882b2ccba99f9cf94878f597b24c5185560a86 (patch) | |
tree | d686357de417b042f503a1b81be7d0931de9338a /support | |
parent | 603754423569ecba037123cdffaf3b7a9aa31160 (diff) | |
download | PeerTube-e2882b2ccba99f9cf94878f597b24c5185560a86.tar.gz PeerTube-e2882b2ccba99f9cf94878f597b24c5185560a86.tar.zst PeerTube-e2882b2ccba99f9cf94878f597b24c5185560a86.zip |
Sticking to one env-var management system (#2247)
* Sticking to one env-var management system
Starting with the Postgres container so that you only have to set overlapping environment variables in one place.
* Moving Postfix envvars pt 1
* Moving Postfix envvars pt 2 .env file
* Added missing envvars.
* Adding functioning glue
Suggest something better if you wish.
* removed IP from example
* Removed default network from update.
Diffstat (limited to 'support')
-rw-r--r-- | support/docker/production/.env | 9 | ||||
-rw-r--r-- | support/docker/production/docker-compose.yml | 10 |
2 files changed, 11 insertions, 8 deletions
diff --git a/support/docker/production/.env b/support/docker/production/.env index c8393d0ce..95ca42d69 100644 --- a/support/docker/production/.env +++ b/support/docker/production/.env | |||
@@ -1,5 +1,9 @@ | |||
1 | PEERTUBE_DB_USERNAME=postgres_user | 1 | POSTGRES_USER=peertube |
2 | PEERTUBE_DB_PASSWORD=postgres_password | 2 | POSTGRES_PASSWORD=peertube |
3 | POSTGRES_DB=peertube | ||
4 | PEERTUBE_DB_USERNAME=$(POSTGRES_USER) | ||
5 | PEERTUBE_DB_PASSWORD=$(POSTGRES_PASSWORD) | ||
6 | PEERTUBE_DB_HOSTNAME=postgres | ||
3 | PEERTUBE_WEBSERVER_HOSTNAME=domain.tld | 7 | PEERTUBE_WEBSERVER_HOSTNAME=domain.tld |
4 | PEERTUBE_WEBSERVER_PORT=443 | 8 | PEERTUBE_WEBSERVER_PORT=443 |
5 | PEERTUBE_WEBSERVER_HTTPS=true | 9 | PEERTUBE_WEBSERVER_HTTPS=true |
@@ -14,6 +18,7 @@ PEERTUBE_SMTP_FROM=noreply@domain.tld | |||
14 | PEERTUBE_SMTP_TLS=false | 18 | PEERTUBE_SMTP_TLS=false |
15 | PEERTUBE_SMTP_DISABLE_STARTTLS=false | 19 | PEERTUBE_SMTP_DISABLE_STARTTLS=false |
16 | PEERTUBE_ADMIN_EMAIL=admin@domain.tld | 20 | PEERTUBE_ADMIN_EMAIL=admin@domain.tld |
21 | POSTFIX_myhostname=${PEERTUBE_WEBSERVER_HOSTNAME} | ||
17 | # /!\ Prefer to use the PeerTube admin interface to set the following configurations /!\ | 22 | # /!\ Prefer to use the PeerTube admin interface to set the following configurations /!\ |
18 | #PEERTUBE_SIGNUP_ENABLED=true | 23 | #PEERTUBE_SIGNUP_ENABLED=true |
19 | #PEERTUBE_TRANSCODING_ENABLED=true | 24 | #PEERTUBE_TRANSCODING_ENABLED=true |
diff --git a/support/docker/production/docker-compose.yml b/support/docker/production/docker-compose.yml index 3786ae675..9f6c47eca 100644 --- a/support/docker/production/docker-compose.yml +++ b/support/docker/production/docker-compose.yml | |||
@@ -47,10 +47,8 @@ services: | |||
47 | 47 | ||
48 | postgres: | 48 | postgres: |
49 | image: postgres:10-alpine | 49 | image: postgres:10-alpine |
50 | environment: | 50 | env_file: |
51 | POSTGRES_USER: ${PEERTUBE_DB_USERNAME} | 51 | - .env |
52 | POSTGRES_PASSWORD: ${PEERTUBE_DB_PASSWORD} | ||
53 | POSTGRES_DB: peertube | ||
54 | volumes: | 52 | volumes: |
55 | - ./docker-volume/db:/var/lib/postgresql/data | 53 | - ./docker-volume/db:/var/lib/postgresql/data |
56 | restart: "always" | 54 | restart: "always" |
@@ -67,8 +65,8 @@ services: | |||
67 | 65 | ||
68 | postfix: | 66 | postfix: |
69 | image: mwader/postfix-relay | 67 | image: mwader/postfix-relay |
70 | environment: | 68 | env_file: |
71 | - POSTFIX_myhostname=${PEERTUBE_WEBSERVER_HOSTNAME} | 69 | - .env |
72 | labels: | 70 | labels: |
73 | traefik.enable: "false" | 71 | traefik.enable: "false" |
74 | restart: "always" | 72 | restart: "always" |