2024-11-12 22:45:50 +00:00
|
|
|
# docker-dotclear:*
|
2024-11-11 16:56:16 +00:00
|
|
|
# /etc/nginx/snippets/snippets_blogs.conf
|
|
|
|
# Dotclear nginx default server blogs configurations
|
|
|
|
|
|
|
|
listen 80;
|
|
|
|
index index.php index.html;
|
|
|
|
root /var/www/dotclear/app;
|
|
|
|
client_max_body_size 32m;
|
|
|
|
set $dc_blog_id default;
|
|
|
|
|
|
|
|
# Blogs public paths
|
|
|
|
location ~ /([^/]+)/public {
|
|
|
|
root /var/www/dotclear/blogs;
|
|
|
|
rewrite /([^/]+)/public/(.*) /$1/$2 break;
|
|
|
|
try_files $uri =404;
|
|
|
|
}
|
|
|
|
|
|
|
|
# Dotclear files
|
|
|
|
location / {
|
|
|
|
set $dc_blog_id default;
|
|
|
|
try_files $uri $uri/ @dotclear_path_info;
|
|
|
|
}
|
|
|
|
|
|
|
|
# Blogs path_info URL
|
|
|
|
location @dotclear_path_info {
|
|
|
|
# URI first part is blog id
|
|
|
|
if ($request_uri ~ ^/([^/]+)) {
|
|
|
|
set $dc_blog_id $1;
|
|
|
|
rewrite ^/([^/]+)(/.*|$) /index.php$2 last;
|
|
|
|
}
|
|
|
|
rewrite ^/(.*) /index.php/$1 last;
|
|
|
|
}
|