added nginx to serve /repo folder for fdroid app
This commit is contained in:
@@ -10,8 +10,11 @@ WORKDIR /fdroid
|
|||||||
RUN fdroid init -v
|
RUN fdroid init -v
|
||||||
RUN fdroid update
|
RUN fdroid update
|
||||||
|
|
||||||
# Second stage: serve the /repo directory using Filebrowser
|
# Second stage: serve the /repo directory using Filebrowser and NGINX
|
||||||
FROM filebrowser/filebrowser AS final
|
FROM filebrowser/filebrowser AS final
|
||||||
|
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
|
||||||
CMD ["--config", "/config/settings.json"]
|
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
|
EXPOSE 8084
|
||||||
|
CMD ["--config", "/config/settings.json", "&", "nginx", "&", "wait"]
|
||||||
@@ -10,7 +10,7 @@ services:
|
|||||||
- fbdb:/database
|
- fbdb:/database
|
||||||
ports:
|
ports:
|
||||||
- ${WEB_PORT-8083}:80
|
- ${WEB_PORT-8083}:80
|
||||||
|
- ${REPO_PORT-8084}:8084
|
||||||
volumes:
|
volumes:
|
||||||
fbdb:
|
fbdb:
|
||||||
repo:
|
repo:
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ services:
|
|||||||
- TZ=Europe/Rome
|
- TZ=Europe/Rome
|
||||||
ports:
|
ports:
|
||||||
- 8083:80
|
- 8083:80
|
||||||
|
- 8084:8084
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
|
|||||||
9
nginx.conf
Normal file
9
nginx.conf
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
server {
|
||||||
|
listen *:8084;
|
||||||
|
server_name localhost;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
root /fdroid/repo;
|
||||||
|
autoindex on;
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user