How to change correctly postgresql 'datestyle' parameter in docker-compose.yml?
In container from image in /var/lib/postgresql/data/postgresql.conf the defulat is datestyle = 'iso, mdy', i want to change it to datestyle = 'iso, dmy'.
I've trying next: in docker-compose.yaml:
environment:
- PGDATESTYLE='iso, dmy'
after this get an error while starting container
2023-06-15 07:54:26.859 GMT [51] FATAL: invalid value for parameter "DateStyle": "'iso, dmy'" 2023-06-15 07:54:26.859 GMT [51] DETAIL: Unrecognized key word: "'iso".
then i try in docker-compose.yaml:
services:
pg_base:
command: postgres -c 'datestyle="iso, dmy"'
and get error
2023-06-15 07:56:39.783 GMT [1] FATAL: invalid value for parameter "DateStyle": ""iso, dmy"" 2023-06-15 07:56:39.783 GMT [1] DETAIL: Unrecognized key word: "iso, dmy".