forked from fesco/docs
antora deletes and recreates public/ every time the docs are rebuilt; mounting public/ directly meant that when build.sh, the existing nginx container didn't see the new docs. Instead of mounting public/ directly into the nginx default webroot, mount the parent directory at /antora, and install a tiny nginx configuration file to point the webroot at the right place.
14 lines
269 B
Nginx Configuration File
14 lines
269 B
Nginx Configuration File
server {
|
|
listen 80;
|
|
server_name localhost;
|
|
|
|
location / {
|
|
root /antora/public;
|
|
index index.html index.htm;
|
|
}
|
|
|
|
error_page 500 502 503 504 /50x.html;
|
|
location = /50x.html {
|
|
root /usr/share/nginx/html;
|
|
}
|
|
}
|