Skip to content

Commit fc67676

Browse files
committed
Put "docker-entrypoint.sh" in PATH (with backwards-compat symlink)
1 parent e430162 commit fc67676

File tree

12 files changed

+36
-36
lines changed

12 files changed

+36
-36
lines changed

9.2/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

9.2/alpine/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

9.3/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

9.3/alpine/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

9.4/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

9.4/alpine/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

9.5/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

9.5/alpine/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

9.6/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

9.6/alpine/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

Dockerfile-alpine.template

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ ENV PGDATA /var/lib/postgresql/data
124124
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
125125
VOLUME /var/lib/postgresql/data
126126

127-
COPY docker-entrypoint.sh /
128-
129-
ENTRYPOINT ["/docker-entrypoint.sh"]
127+
COPY docker-entrypoint.sh /usr/local/bin/
128+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
129+
ENTRYPOINT ["docker-entrypoint.sh"]
130130

131131
EXPOSE 5432
132132
CMD ["postgres"]

Dockerfile-debian.template

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ ENV PGDATA /var/lib/postgresql/data
6161
RUN mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 777 "$PGDATA" # this 777 will be replaced by 700 at runtime (allows semi-arbitrary "--user" values)
6262
VOLUME /var/lib/postgresql/data
6363

64-
COPY docker-entrypoint.sh /
65-
66-
ENTRYPOINT ["/docker-entrypoint.sh"]
64+
COPY docker-entrypoint.sh /usr/local/bin/
65+
RUN ln -s usr/local/bin/docker-entrypoint.sh / # backwards compat
66+
ENTRYPOINT ["docker-entrypoint.sh"]
6767

6868
EXPOSE 5432
6969
CMD ["postgres"]

0 commit comments

Comments
 (0)