removed PG_LOCALE option (doesn't work!)

This commit is contained in:
Sameer Naik
2015-11-28 13:13:44 +05:30
parent a6a2a78585
commit 1f87e4aa1b
4 changed files with 2 additions and 24 deletions
+1
View File
@@ -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
-12
View File
@@ -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.
-3
View File
@@ -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}
+1 -9
View File
@@ -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