diff --git a/Changelog.md b/Changelog.md index 638ad1e..34b1ba1 100644 --- a/Changelog.md +++ b/Changelog.md @@ -10,6 +10,7 @@ - `DB_LOCALE` config parameter renamed to `PG_LOCALE` - complete rewrite of the README - add support for creating backups using `pg_basebackup` +- removed `PG_LOCALE` option (doesn't work!) **9.4-2** - added replication options diff --git a/README.md b/README.md index ed46636..d17a492 100644 --- a/README.md +++ b/README.md @@ -102,18 +102,6 @@ mkdir -p /srv/docker/postgresql chcon -Rt svirt_sandbox_file_t /srv/docker/postgresql ``` -## Setting the default locale - -*This is an experimental option. Please share your feedback and/or suggestions* - -Using the `PG_LOCALE` variable you can set the default [locale](http://www.postgresql.org/docs/9.4/static/locale.html) for the database cluster. The default value of this variable is `PG_LOCALE=C`. - -[Example redacted] - -> **Note** -> -> This variable is effective only on the first run of the container as it is used while creating a new PostgreSQL database cluster using [initdb](http://www.postgresql.org/docs/9.4/static/app-initdb.html) - ## Trusting local connections By default connections to the PostgreSQL server need to authenticated using a password. If desired you can trust connections from the local network using the `PG_TRUST_LOCALNET` variable. diff --git a/runtime/env-defaults b/runtime/env-defaults index 3cf29fa..a1bd4ed 100644 --- a/runtime/env-defaults +++ b/runtime/env-defaults @@ -2,9 +2,6 @@ PG_SSL=${PG_SSL:-} -PG_LOCALE=${PG_LOCALE:-$DB_LOCALE} # backward compatibility -PG_LOCALE=${PG_LOCALE:-C} - PG_TRUST_LOCALNET=${PG_TRUST_LOCALNET:-$PSQL_TRUST_LOCALNET} # backward compatibility PG_TRUST_LOCALNET=${PG_TRUST_LOCALNET:-false} diff --git a/runtime/functions b/runtime/functions index 21759ab..1bd5f1f 100755 --- a/runtime/functions +++ b/runtime/functions @@ -24,13 +24,6 @@ map_uidgid() { fi } -locale_gen() { - if [[ $PG_LOCALE != C ]]; then - echo "Generating locale \"${PG_LOCALE}\"..." - locale-gen ${PG_LOCALE} >/dev/null - fi -} - create_datadir() { echo "Initializing datadir..." mkdir -p ${PG_HOME} @@ -210,7 +203,7 @@ initialize_database() { fi exec_as_postgres ${PG_BINDIR}/initdb --pgdata=${PG_DATADIR} \ - --username=${PG_USER} --encoding=unicode --locale=${PG_LOCALE} --auth=trust >/dev/null + --username=${PG_USER} --encoding=unicode --auth=trust >/dev/null if [[ -n ${PG_OLD_VERSION} ]]; then PG_OLD_BINDIR=/usr/lib/postgresql/${PG_OLD_VERSION}/bin @@ -344,7 +337,6 @@ fi # default behaviour is to launch postgres if [[ -z ${1} ]]; then map_uidgid - locale_gen create_datadir create_certdir