commit 6fb8d75ed79113e3d2074e9685b0b1dde995bbc8 Author: ViViDboarder Date: Tue Oct 11 23:22:01 2016 +0000 Initial commit Things appear to be working. No documentation yet diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..720355d --- /dev/null +++ b/.dockerignore @@ -0,0 +1,2 @@ +tags +README.md diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6e92f57 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +tags diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..8129c99 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,57 @@ +FROM resin/rpi-raspbian:jessie +MAINTAINER ViViDboarder + +# Instal Python dependencies +RUN echo 'deb-src http://archive.raspbian.org/raspbian jessie main contrib non-free rpi firmware' >> /etc/apt/sources.list && \ + apt-get update && apt-get install -y \ + wget \ + zlib1g \ + zlib1g-dev \ + --no-install-recommends && \ + apt-get build-dep -y python2.7 && \ + rm -rf /var/lib/apt/lists/* + +# Install python with zlib support +RUN wget https://www.python.org/ftp/python/2.7.12/Python-2.7.12.tgz && \ + tar xvf Python-2.7.12.tgz && \ + cd Python-2.7.12 && \ + ./configure && make && make install && \ + cd .. && rm -fr Python-2.7.12 Python-2.7.12.tgz + +# Install motion dependencies +RUN apt-get update && apt-get install -y \ + curl \ + libav-tools \ + libavformat56 \ + libcurl4-openssl-dev \ + libjpeg-dev \ + libssl-dev \ + motion \ + python-dev \ + python-pip \ + v4l-utils \ + --no-install-recommends && \ + rm -rf /var/lib/apt/lists/* + +# Link avconv to ffmpeg because ffmpeg was forked in Debian +RUN ln -s /usr/bin/avconv /usr/bin/ffmpeg + +# Install motioneye +RUN pip install motioneye + +# Create config dir +RUN mkdir -p /etc/motioneye +VOLUME /etc/motioneye +# Create data dir +RUN mkdir -p /var/lib/motioneye +VOLUME /var/lib/motioneye + +EXPOSE 8765 + +# RUN useradd motioneye +# RUN chown -R motioneye /etc/motioneye /var/lib/motioneye +# USER motioneye + +CMD test -e /etc/motioneye/motioneye.conf || \ + cp /usr/local/share/motioneye/extra/motioneye.conf.sample /etc/motioneye/motioneye.conf ; \ + /usr/local/bin/meyectl startserver -c /etc/motioneye/motioneye.conf diff --git a/README.md b/README.md new file mode 100644 index 0000000..8861183 --- /dev/null +++ b/README.md @@ -0,0 +1,5 @@ +# rpi-motioneye + +Work in progress Docker image for running Motioneye on a Raspberry Pi + +So far, it appears to work fine. Documentation to come... Use at your own risk