Skip to content

Commit

Permalink
fix: serve files on /docs without trailing /
Browse files Browse the repository at this point in the history
  • Loading branch information
MoritzWeber0 committed Aug 10, 2022
1 parent 421c017 commit cde467a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/user/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ FROM nginxinc/nginx-unprivileged:latest
EXPOSE 8080

COPY nginx.conf /etc/nginx/nginx.conf
COPY --from=build /opt/docs/site /usr/share/nginx/html
COPY --from=build /opt/docs/site /usr/share/nginx/html/docs
5 changes: 2 additions & 3 deletions docs/user/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ http {
server_name _;

root /usr/share/nginx/html;
error_page 404 /404.html;
error_page 404 /docs/404.html;

location /docs {
rewrite ^/docs(.*)$ $1 last;
index index.html;
}

}
}
}

0 comments on commit cde467a

Please sign in to comment.