Skip to content

Commit a7ba7f2

Browse files
committed
Remove "doc" and "man" from Alpine images for size
``` postgres 9.6-alpine-after 83c9edfc60a1 2 minutes ago 32.53 MB postgres 9.6-alpine-before 56409b6ffc83 9 minutes ago 49.43 MB ```
1 parent a00e979 commit a7ba7f2

File tree

6 files changed

+12
-0
lines changed

6 files changed

+12
-0
lines changed

9.2/alpine/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

9.3/alpine/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

9.4/alpine/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

9.5/alpine/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

9.6/alpine/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

Dockerfile-alpine.template

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ RUN set -ex \
106106
&& rm -rf \
107107
/usr/src/postgresql \
108108
/usr/local/include/* \
109+
/usr/local/share/doc \
110+
/usr/local/share/man \
109111
&& find /usr/local -name '*.a' -delete
110112

111113
# make the sample config easier to munge (and "correct by default")

0 commit comments

Comments
 (0)