Make it easier to run

This commit is contained in:
Gervasio Marchand 2022-12-04 10:41:02 -03:00
parent 253f17108a
commit 51d8ae9638
No known key found for this signature in database
GPG Key ID: B7736CB188DD0A38
2 changed files with 10 additions and 2 deletions

View File

@ -9,5 +9,6 @@ FROM mcr.microsoft.com/dotnet/aspnet:6.0.11-alpine3.16
VOLUME ["/data"]
ENV CONFIG_PATH=/data/config.json
COPY --from=builder /app /app
RUN ln -s /app/FakeRelay.Cli /bin/cli
RUN ln -s /app/FakeRelay.Web /bin/web
COPY entrypoint.sh /app/entrypoint.sh
RUN ln -s /app/FakeRelay.Cli /bin/cli && ln -s /app/FakeRelay.Web /bin/web && chmod +x /app/entrypoint.sh
ENTRYPOINT [ "/app/entrypoint.sh" ]

7
entrypoint.sh Normal file
View File

@ -0,0 +1,7 @@
#!/bin/ash
if [ "$1" = "web" ]; then
web
else
cli "$@"
fi