Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions 10/root/usr/bin/run-postgresql
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

export ENABLE_REPLICATION=${ENABLE_REPLICATION:-false}

# Load secrets from files mounted on the filesystem and only expose them to this process.
# This allows kubernetes to mount secrets as files in a directory rather than exposing them in the ENV.
# For example: mount secret with key username as /run/secrets/postgresql/POSTGRESQL_USER
for file in /run/secrets/postgresql/*
do
[ -e "$file" ] || continue
export "$(basename $file)=$(cat $file)"
done

set -eu
export_vars=$(cgroup-limits) ; export $export_vars

Expand Down
9 changes: 9 additions & 0 deletions 12/root/usr/bin/run-postgresql
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

export ENABLE_REPLICATION=${ENABLE_REPLICATION:-false}

# Load secrets from files mounted on the filesystem and only expose them to this process.
# This allows kubernetes to mount secrets as files in a directory rather than exposing them in the ENV.
# For example: mount secret with key username as /run/secrets/postgresql/POSTGRESQL_USER
for file in /run/secrets/postgresql/*
do
[ -e "$file" ] || continue
export "$(basename $file)=$(cat $file)"
done

set -eu
export_vars=$(cgroup-limits) ; export $export_vars

Expand Down
9 changes: 9 additions & 0 deletions 13/root/usr/bin/run-postgresql
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

export ENABLE_REPLICATION=${ENABLE_REPLICATION:-false}

# Load secrets from files mounted on the filesystem and only expose them to this process.
# This allows kubernetes to mount secrets as files in a directory rather than exposing them in the ENV.
# For example: mount secret with key username as /run/secrets/postgresql/POSTGRESQL_USER
for file in /run/secrets/postgresql/*
do
[ -e "$file" ] || continue
export "$(basename $file)=$(cat $file)"
done

set -eu
export_vars=$(cgroup-limits) ; export $export_vars

Expand Down
9 changes: 9 additions & 0 deletions src/root/usr/bin/run-postgresql
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

export ENABLE_REPLICATION=${ENABLE_REPLICATION:-false}

# Load secrets from files mounted on the filesystem and only expose them to this process.
# This allows kubernetes to mount secrets as files in a directory rather than exposing them in the ENV.
# For example: mount secret with key username as /run/secrets/postgresql/POSTGRESQL_USER
for file in /run/secrets/postgresql/*
do
[ -e "$file" ] || continue
export "$(basename $file)=$(cat $file)"
done

set -eu
export_vars=$(cgroup-limits) ; export $export_vars

Expand Down