Enable SSL for connections to database

Since the database can be exposed to the outer world, it seems better to
have an encrypted connection to it.
We automatically generate a self-signed certificate since it's only used
to encrypt the connection but one can easily replace it by a custom one,
just overwrite `server.crt` and `server.key` in the
/var/lib/dokku/services/postgres/DB_NAME/data directory.
This commit is contained in:
Loïc Guitaut
2015-12-01 12:36:54 +01:00
parent 4e0397610b
commit 3441be809d
4 changed files with 21 additions and 0 deletions

View File

@@ -15,6 +15,7 @@ cd -
rm -rf $DOKKU_ROOT/plugins/service
mkdir -p $DOKKU_ROOT/plugins/service
find ./ -maxdepth 1 -type f -exec cp '{}' $DOKKU_ROOT/plugins/service \;
cp -r ./scripts "$DOKKU_ROOT/plugins/service"
if [[ ! -f $BIN_STUBS/plugn ]]; then
wget -O- "$PLUGN_URL" | tar xzf - -C "$BIN_STUBS"