use a more strict vhost config
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details

This commit is contained in:
Robert Kaussow 2019-09-29 15:07:44 +02:00
parent f4368414f4
commit 22754f9bf9
5 changed files with 18 additions and 11 deletions

View File

@ -1,2 +1,3 @@
* BUGFIX
* fix port in healthcheck script
* use a more strict vhost

View File

@ -24,6 +24,7 @@ RUN apk --update add --virtual .build-deps tar curl && \
apk del .build-deps && \
rm -rf /var/cache/apk/* && \
rm -rf /tmp/* && \
rm -rf /var/www/app/ChangeLog /var/www/app/config.default.php && \
mkdir -p /var/run/php && \
chown -R nginx /var/run/php && \
mkdir -p /var/lib/php/tmp_upload && \

View File

@ -4,12 +4,12 @@ services:
kanboard:
image: xoxys/kanboard:latest
ports:
- "80:80"
- "80:8080"
volumes:
- kanboard_data:/var/www/app/data
- kanboard_plugins:/var/www/app/plugins
environment:
KANBOARD_PLUGIN_INSTALLER: "true"
KANBOARD_PLUGIN_INSTALLER: "true"
volumes:
kanboard_data:

View File

@ -9,16 +9,12 @@ server {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php/php-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_index index.php;
include fastcgi_params;
location ~ /plugins/.*/Assets/ {
allow all;
}
location ~ /data {
location ~ /(app|data|libs|plugins|vendor|cli) {
deny all;
return 404;
}
@ -30,6 +26,15 @@ server {
return 404;
}
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php/php-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_index index.php;
include fastcgi_params;
}
location ~* ^.+\.(ico|jpg|gif|png|css|js|svg|eot|ttf|woff|woff2|otf)$ {
log_not_found off;
expires 7d;

View File

@ -1,6 +1,6 @@
#!/bin/sh
/usr/local/bin/gomplate -V -o /etc/php7/php.ini -f /etc/templates/php.ini.tmpl 1>/dev/null
/usr/local/bin/gomplate -V -o /var/www/app/config.php -f /etc/templates/config.php.tmpl 1>/dev/null
/usr/local/bin/gomplate -V -o /var/www/app/data/config.php -f /etc/templates/config.php.tmpl 1>/dev/null
exec supercronic -split-logs /etc/crontabs/nginx 1>/dev/null &
exec php-fpm7 -F &