Added nginx to serve /repo folder

This commit is contained in:
Daniele Viti
2023-09-12 17:57:30 +02:00
parent 9330b90080
commit b26893d8b3
2 changed files with 17 additions and 8 deletions

View File

@@ -15,6 +15,9 @@ FROM filebrowser/filebrowser AS final
RUN apk update && apk add nginx RUN apk update && apk add nginx
COPY --from=build /fdroid/ / COPY --from=build /fdroid/ /
COPY settings.json /config/settings.json COPY settings.json /config/settings.json
COPY nginx.conf /etc/nginx/conf.d/default.conf RUN rm /etc/nginx/nginx.conf
COPY nginx.conf /etc/nginx/nginx.conf
EXPOSE 8084 EXPOSE 8084
CMD ["--config", "/config/settings.json", "&", "nginx", "&", "wait"] ENTRYPOINT []
#CMD ["sh", "-c", "while true; do sleep 1; done"]
CMD ["sh", "-c", "nginx && /filebrowser --config /config/settings.json"]

View File

@@ -1,9 +1,15 @@
server { events {
listen *:8084; worker_connections 1024;
}
http {
server {
listen 8084;
server_name localhost; server_name localhost;
location / { location / {
root /fdroid/repo; root /fdroid/repo;
autoindex on; autoindex on;
} }
}
} }