From 64c0f287ed2e341f627d432217212095dbe15bca Mon Sep 17 00:00:00 2001 From: Alexey Khit Date: Sun, 21 Aug 2022 00:34:53 +0300 Subject: [PATCH] Adds ffmpeg and ngrok to docker --- build/hassio/Dockerfile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/build/hassio/Dockerfile b/build/hassio/Dockerfile index 28c9de26..fc12eb2c 100644 --- a/build/hassio/Dockerfile +++ b/build/hassio/Dockerfile @@ -1,11 +1,19 @@ ARG BUILD_FROM FROM $BUILD_FROM -RUN apk add --no-cache git go +RUN apk add --no-cache git go ffmpeg + +ARG BUILD_ARCH WORKDIR app RUN git clone https://github.com/AlexxIT/go2rtc . RUN CGO_ENABLED=0 go build -ldflags "-s -w" -trimpath +# https://github.com/home-assistant/docker-base/blob/master/alpine/Dockerfile +RUN if [ "${BUILD_ARCH}" = "aarch64" ]; then BUILD_ARCH="arm64"; \ + elif [ "${BUILD_ARCH}" = "armv7" ]; then BUILD_ARCH="arm"; fi \ + && curl $(curl -s "https://raw.githubusercontent.com/ngrok/docker-ngrok/main/releases.json" | jq -r ".${BUILD_ARCH}.url") -o ngrok.zip \ + && unzip ngrok + CMD [ "/app/go2rtc", "-config", "/config/go2rtc.yaml" ]