Replies: 1 comment 1 reply
-
If you need to install new packages, I would suggest either a slightly more complex container command ( We do not plan to add/support/maintain an additional "root" init directory (especially since the whole point of that directory is that the server is started up while it's running those because anything else could be accomplished with a custom command as shown above; we don't want to ever run the server itself as root). The entrypoint is also " |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I am using the vanilla image of postgres (17-alpine), to which I want to install the pg_cron extension. For what I have read, the steps go down to install the pg_cron package using apk, add some config lines to postgreqsl.conf, and run a sql to install the extension.
I have searching for the last hour, and all the solutions pointed at go in the direction of generating a new image based on the version I want... but is this really needed? This introduces also a maintenance burden for something that takes few seconds to install.
The issue happens with the installation of the package itself, as it requires root permissions and by then the switch to postgres user has already happened. My question is: Do you guys see any issue in extending the current docker-entrypoint.sh so that right before the script gets restarted with the postgres user, something similar to
is run?
Beta Was this translation helpful? Give feedback.
All reactions