forked from coop-cloud/wordpress
Compare commits
12 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| cf54575187 | |||
| b4db12f09c | |||
| e4b87c8ab9 | |||
| 7e170adbb4 | |||
| 66e0687456 | |||
| 9209f007cb | |||
| 69cf451b98 | |||
| 73a2e98d2e | |||
| 0e229168fc | |||
| 332ab0b97d | |||
|
3b598e82dd
|
|||
|
8e81f3f81c
|
21
.gitignore
vendored
21
.gitignore
vendored
@ -1 +1,22 @@
|
|||||||
|
# direnv
|
||||||
/.envrc
|
/.envrc
|
||||||
|
|
||||||
|
# Environment files (may contain secrets)
|
||||||
|
.env
|
||||||
|
|
||||||
|
# Logs
|
||||||
|
*.log
|
||||||
|
|
||||||
|
# OS metadata
|
||||||
|
.DS_Store
|
||||||
|
Thumbs.db
|
||||||
|
|
||||||
|
# Editor/IDE
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
*~
|
||||||
|
*.bak
|
||||||
|
.idea/
|
||||||
|
.vscode/
|
||||||
|
.project
|
||||||
|
.classpath
|
||||||
|
|||||||
12
abra.sh
12
abra.sh
@ -1,5 +1,5 @@
|
|||||||
export PHP_UPLOADS_CONF_VERSION=v4
|
export PHP_UPLOADS_CONF_VERSION=v4
|
||||||
export ENTRYPOINT_CONF_VERSION=v7
|
export ENTRYPOINT_CONF_VERSION=v8
|
||||||
export ENTRYPOINT_MAILRELAY_CONF_VERSION=v2
|
export ENTRYPOINT_MAILRELAY_CONF_VERSION=v2
|
||||||
export MSMTP_CONF_VERSION=v4
|
export MSMTP_CONF_VERSION=v4
|
||||||
export HTACCESS_CONF_VERSION=v3
|
export HTACCESS_CONF_VERSION=v3
|
||||||
@ -42,11 +42,11 @@ core_install(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
enable_auto_updates(){
|
enable_auto_updates(){
|
||||||
wp plugin deactivate disable-update-notifications --allow-root
|
wp "plugin deactivate disable-update-notifications --allow-root"
|
||||||
wp plugin uninstall disable-update-notifications --allow-root
|
wp "plugin uninstall disable-update-notifications --allow-root"
|
||||||
wp option delete disable_notification_setting --allow-root
|
wp "option delete disable_notification_setting --allow-root"
|
||||||
wp plugin auto-updates enable --all --allow-root
|
wp "plugin auto-updates enable --all --allow-root"
|
||||||
wp theme auto-updates enable --all --allow-root
|
wp "theme auto-updates enable --all --allow-root"
|
||||||
}
|
}
|
||||||
|
|
||||||
disable_auto_updates(){
|
disable_auto_updates(){
|
||||||
|
|||||||
@ -62,7 +62,7 @@ services:
|
|||||||
- "traefik.http.middlewares.${STACK_NAME}-redirect.redirectregex.replacement=https://${DOMAIN}/$${2}"
|
- "traefik.http.middlewares.${STACK_NAME}-redirect.redirectregex.replacement=https://${DOMAIN}/$${2}"
|
||||||
- "traefik.http.middlewares.${STACK_NAME}-redirect.redirectregex.permanent=true"
|
- "traefik.http.middlewares.${STACK_NAME}-redirect.redirectregex.permanent=true"
|
||||||
- "coop-cloud.${STACK_NAME}.timeout=${TIMEOUT}"
|
- "coop-cloud.${STACK_NAME}.timeout=${TIMEOUT}"
|
||||||
- "coop-cloud.${STACK_NAME}.version=2.19.1+6.9.4"
|
- "coop-cloud.${STACK_NAME}.version=2.19.2+6.9.4"
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: "mariadb:12.2"
|
image: "mariadb:12.2"
|
||||||
|
|||||||
@ -42,6 +42,20 @@ define('FORCE_SSL_ADMIN', true );
|
|||||||
define('COOKIE_DOMAIN', \$_SERVER['HTTP_HOST']);"
|
define('COOKIE_DOMAIN', \$_SERVER['HTTP_HOST']);"
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
|
||||||
|
UPLOADS_HTACCESS=/var/www/html/wp-content/uploads/.htaccess
|
||||||
|
if [ ! -f "$UPLOADS_HTACCESS" ]; then
|
||||||
|
mkdir -p /var/www/html/wp-content/uploads
|
||||||
|
cat > "$UPLOADS_HTACCESS" <<'EOF'
|
||||||
|
# Prevent PHP execution in uploads directory
|
||||||
|
<FilesMatch "\.(?i:php|phtml|phar)$">
|
||||||
|
Require all denied
|
||||||
|
</FilesMatch>
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
chown -R --from=root:root www-data:www-data /var/www/html/wp-content/
|
||||||
|
|
||||||
if [ -n "$@" ]; then
|
if [ -n "$@" ]; then
|
||||||
"$@"
|
"$@"
|
||||||
fi
|
fi
|
||||||
|
|||||||
@ -3,13 +3,6 @@
|
|||||||
Require all denied
|
Require all denied
|
||||||
</FilesMatch>
|
</FilesMatch>
|
||||||
|
|
||||||
# Prevent PHP execution in uploads directory
|
|
||||||
<Directory /var/www/html/wp-content/uploads>
|
|
||||||
<FilesMatch "\.(?i:php|phtml|phar)$">
|
|
||||||
Require all denied
|
|
||||||
</FilesMatch>
|
|
||||||
</Directory>
|
|
||||||
|
|
||||||
{{ if eq (env "MULTISITE") "" -}}
|
{{ if eq (env "MULTISITE") "" -}}
|
||||||
# BEGIN WordPress
|
# BEGIN WordPress
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user