Skip to content

Commit

Permalink
Store secrets in separate .env file
Browse files Browse the repository at this point in the history
This allows a downstream-user to keep .env under some version control
without worrying about password leakage.
  • Loading branch information
0x326 committed Aug 20, 2020
1 parent bec928c commit 3589c42
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
*.swp
.env
.env.bak
secrets.env
secrets.env.bak
docker-compose.override.yml
12 changes: 12 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ services:
- ${CONFIG}/web:/config:Z
- ${CONFIG}/web/letsencrypt:/etc/letsencrypt:Z
- ${CONFIG}/transcripts:/usr/share/jitsi-meet/transcripts:Z
env_file:
- .env
- secrets.env
environment:
- ENABLE_AUTH
- ENABLE_GUESTS
Expand Down Expand Up @@ -55,6 +58,9 @@ services:
volumes:
- ${CONFIG}/prosody/config:/config:Z
- ${CONFIG}/prosody/prosody-plugins-custom:/prosody-plugins-custom:Z
env_file:
- .env
- secrets.env
environment:
- AUTH_TYPE
- ENABLE_AUTH
Expand Down Expand Up @@ -116,6 +122,9 @@ services:
restart: ${RESTART_POLICY}
volumes:
- ${CONFIG}/jicofo:/config:Z
env_file:
- .env
- secrets.env
environment:
- AUTH_TYPE
- ENABLE_AUTH
Expand Down Expand Up @@ -148,6 +157,9 @@ services:
- '${JVB_TCP_PORT}:${JVB_TCP_PORT}'
volumes:
- ${CONFIG}/jvb:/config:Z
env_file:
- .env
- secrets.env
environment:
- DOCKER_HOST_ADDRESS
- XMPP_AUTH_DOMAIN
Expand Down
2 changes: 1 addition & 1 deletion gen-passwords.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ sed -i.bak \
-e "s#JIGASI_XMPP_PASSWORD=.*#JIGASI_XMPP_PASSWORD=${JIGASI_XMPP_PASSWORD}#g" \
-e "s#JIBRI_RECORDER_PASSWORD=.*#JIBRI_RECORDER_PASSWORD=${JIBRI_RECORDER_PASSWORD}#g" \
-e "s#JIBRI_XMPP_PASSWORD=.*#JIBRI_XMPP_PASSWORD=${JIBRI_XMPP_PASSWORD}#g" \
"$(dirname "$0")/.env"
"$(dirname "$0")/secrets.env"

0 comments on commit 3589c42

Please sign in to comment.