Skip to content

Commit 5c66950

Browse files
authored
Merge pull request #535 from infosiftr/cache
Add wp-content/cache to pre-created directories
2 parents 598769a + 1de7b5a commit 5c66950

File tree

11 files changed

+22
-11
lines changed

11 files changed

+22
-11
lines changed

Dockerfile-alpine.template

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,9 @@ RUN set -ex; \
8181
rm wordpress.tar.gz; \
8282
chown -R www-data:www-data /usr/src/wordpress; \
8383
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
84+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8485
mkdir wp-content; \
85-
for dir in /usr/src/wordpress/wp-content/*/; do \
86+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
8687
dir="$(basename "${dir%/}")"; \
8788
mkdir "wp-content/$dir"; \
8889
done; \

Dockerfile-debian.template

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,9 @@ RUN set -ex; \
8686
rm wordpress.tar.gz; \
8787
chown -R www-data:www-data /usr/src/wordpress; \
8888
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
89+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8990
mkdir wp-content; \
90-
for dir in /usr/src/wordpress/wp-content/*/; do \
91+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
9192
dir="$(basename "${dir%/}")"; \
9293
mkdir "wp-content/$dir"; \
9394
done; \

php7.2/apache/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,9 @@ RUN set -ex; \
104104
rm wordpress.tar.gz; \
105105
chown -R www-data:www-data /usr/src/wordpress; \
106106
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
107+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
107108
mkdir wp-content; \
108-
for dir in /usr/src/wordpress/wp-content/*/; do \
109+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
109110
dir="$(basename "${dir%/}")"; \
110111
mkdir "wp-content/$dir"; \
111112
done; \

php7.2/fpm-alpine/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,9 @@ RUN set -ex; \
8080
rm wordpress.tar.gz; \
8181
chown -R www-data:www-data /usr/src/wordpress; \
8282
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
83+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8384
mkdir wp-content; \
84-
for dir in /usr/src/wordpress/wp-content/*/; do \
85+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
8586
dir="$(basename "${dir%/}")"; \
8687
mkdir "wp-content/$dir"; \
8788
done; \

php7.2/fpm/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,9 @@ RUN set -ex; \
8585
rm wordpress.tar.gz; \
8686
chown -R www-data:www-data /usr/src/wordpress; \
8787
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
88+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8889
mkdir wp-content; \
89-
for dir in /usr/src/wordpress/wp-content/*/; do \
90+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
9091
dir="$(basename "${dir%/}")"; \
9192
mkdir "wp-content/$dir"; \
9293
done; \

php7.3/apache/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,9 @@ RUN set -ex; \
105105
rm wordpress.tar.gz; \
106106
chown -R www-data:www-data /usr/src/wordpress; \
107107
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
108+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
108109
mkdir wp-content; \
109-
for dir in /usr/src/wordpress/wp-content/*/; do \
110+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
110111
dir="$(basename "${dir%/}")"; \
111112
mkdir "wp-content/$dir"; \
112113
done; \

php7.3/fpm-alpine/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,9 @@ RUN set -ex; \
8181
rm wordpress.tar.gz; \
8282
chown -R www-data:www-data /usr/src/wordpress; \
8383
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
84+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8485
mkdir wp-content; \
85-
for dir in /usr/src/wordpress/wp-content/*/; do \
86+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
8687
dir="$(basename "${dir%/}")"; \
8788
mkdir "wp-content/$dir"; \
8889
done; \

php7.3/fpm/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,9 @@ RUN set -ex; \
8686
rm wordpress.tar.gz; \
8787
chown -R www-data:www-data /usr/src/wordpress; \
8888
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
89+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8990
mkdir wp-content; \
90-
for dir in /usr/src/wordpress/wp-content/*/; do \
91+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
9192
dir="$(basename "${dir%/}")"; \
9293
mkdir "wp-content/$dir"; \
9394
done; \

php7.4/apache/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,9 @@ RUN set -ex; \
105105
rm wordpress.tar.gz; \
106106
chown -R www-data:www-data /usr/src/wordpress; \
107107
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
108+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
108109
mkdir wp-content; \
109-
for dir in /usr/src/wordpress/wp-content/*/; do \
110+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
110111
dir="$(basename "${dir%/}")"; \
111112
mkdir "wp-content/$dir"; \
112113
done; \

php7.4/fpm-alpine/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,9 @@ RUN set -ex; \
8181
rm wordpress.tar.gz; \
8282
chown -R www-data:www-data /usr/src/wordpress; \
8383
# pre-create wp-content (and single-level children) for folks who want to bind-mount themes, etc so permissions are pre-created properly instead of root:root
84+
# wp-content/cache: https://github.com/docker-library/wordpress/issues/534#issuecomment-705733507
8485
mkdir wp-content; \
85-
for dir in /usr/src/wordpress/wp-content/*/; do \
86+
for dir in /usr/src/wordpress/wp-content/*/ cache; do \
8687
dir="$(basename "${dir%/}")"; \
8788
mkdir "wp-content/$dir"; \
8889
done; \

0 commit comments

Comments
 (0)