ADD file:ea912fd82699af55c10b8136b5dc4b5ce9d08b8a01f9c06f6783d94dc430335a in / |
CMD ["bash"] |
LABEL maintainer=Jack Brierley <jack@thatguyjack.co.uk> |
ARG RUN_UID=0 |
ARG RUN_GID=0 |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c apt-get update && apt install git cifs-utils -y # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c git clone -b dev https://github.com/motioneye-project/motioneye.git /tmp/motioneye # buildkit |
COPY entrypoint.sh /entrypoint.sh # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c case "$(dpkg --print-architecture)" in 'armhf') PACKAGES='python3-distutils'; printf '%b' '[global]\nextra-index-url=https://www.piwheels.org/simple/\n' > /etc/pip.conf;; *) PACKAGES='gcc libcurl4-openssl-dev libssl-dev python3-dev';; esac && apt-get -q update && DEBIAN_FRONTEND="noninteractive" apt-get -qq --option Dpkg::Options::="--force-confnew" --no-install-recommends install ca-certificates curl python3 fdisk $PACKAGES && curl -sSfO 'https://bootstrap.pypa.io/get-pip.py' && python3 get-pip.py # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c python3 -m pip install --no-cache-dir --upgrade pip setuptools wheel && python3 -m pip install --no-cache-dir /tmp/motioneye && python3 -m pip install --no-cache-dir pytz && motioneye_init --skip-systemd --skip-apt-update # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c sed -i "s/^\(motion:[^:]*\):[0-9]*:[0-9]*:\(.*\)/\1:${RUN_UID}:${RUN_GID}:\2/" /etc/passwd && sed -i "s/^\(motion:[^:]*\):[0-9]*:\(.*\)/\1:${RUN_GID}:\2/" /etc/group && mv /etc/motioneye/motioneye.conf /etc/motioneye.conf.sample && mkdir /var/log/motioneye /var/lib/motioneye && chown motion:motion /var/log/motioneye /var/lib/motioneye # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c python3 -m pip uninstall -y pip setuptools wheel && DEBIAN_FRONTEND="noninteractive" apt-get -qq autopurge $PACKAGES && apt-get clean && rm -r /var/lib/apt/lists /var/cache/apt /tmp/motioneye get-pip.py /root/.cache # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c ln -snf /usr/share/zoneinfo/Europe/London /etc/localtime && echo $TZ > /etc/timezone # buildkit |
RUN |2 RUN_UID=0 RUN_GID=0 /bin/sh -c date # buildkit |
VOLUME [/etc/motioneye] |
VOLUME [/var/lib/motioneye] |
EXPOSE map[8765/tcp:{}] |
ENTRYPOINT ["/entrypoint.sh"] |