From 2c113e5fa078c20a130f12b5abe89d42812d8989 Mon Sep 17 00:00:00 2001 From: Allen Porter Date: Sat, 19 Feb 2022 22:01:05 -0800 Subject: [PATCH] Update configuration path in docker file Update the configuration path in the docker file to /config which is a fairly standard location for mounting config files. This will make it easier to play nicely with default helm charts, for example. --- Dockerfile | 7 +++++-- README.md | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5757111..632b398 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,11 +16,14 @@ FROM alpine:3.15 WORKDIR /app + COPY --from=builder /go/src/app/rtsp-to-web /app/ COPY --from=builder /go/src/app/web /app/web -COPY --from=builder /go/src/app/config.json /app/ + +RUN mkdir -p /config +COPY --from=builder /go/src/app/config.json /config ENV GO111MODULE="on" ENV GIN_MODE="release" -CMD ["./rtsp-to-web"] +CMD ["./rtsp-to-web", "--config=/config/config.json"] diff --git a/README.md b/README.md index ad14917..c5bd315 100644 --- a/README.md +++ b/README.md @@ -52,7 +52,7 @@ You may override the configuration `/PATH_TO_C ```bash $ docker run --name rtsp-to-web \ - -v /PATH_TO_CONFIG/config.json:/app/config.json \ + -v /PATH_TO_CONFIG/config.json:/config/config.json \ --network host \ ghcr.io/deepch/rtsptoweb:latest ```