Fix postgres script permissions (#21007)

The initdb.sh and the upgrade.sh scripts in the postgres image
were not owned by the postgres user, which made them failing
with permission denied errors.

Signed-off-by: Mate Hajnal <hajnalmt@gmail.com>
This commit is contained in:
Hajnal Máté 2024-11-25 13:53:19 +01:00 committed by GitHub
parent 969384cd63
commit 4a12623459
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -9,8 +9,9 @@ COPY ./make/photon/db/initdb.sh /initdb.sh
COPY ./make/photon/db/upgrade.sh /upgrade.sh
COPY ./make/photon/db/docker-healthcheck.sh /docker-healthcheck.sh
COPY ./make/photon/db/initial-registry.sql /docker-entrypoint-initdb.d/
RUN chown -R postgres:postgres /docker-entrypoint.sh /docker-healthcheck.sh /docker-entrypoint-initdb.d \
&& chmod u+x /docker-entrypoint.sh /docker-healthcheck.sh
RUN chown -R postgres:postgres /docker-entrypoint.sh /initdb.sh /upgrade.sh \
/docker-healthcheck.sh /docker-entrypoint-initdb.d \
&& chmod u+x /initdb.sh /upgrade.sh /docker-entrypoint.sh /docker-healthcheck.sh
ENTRYPOINT ["/docker-entrypoint.sh", "14", "15"]
HEALTHCHECK CMD ["/docker-healthcheck.sh"]