This repository has been archived by the owner on Apr 20, 2022. It is now read-only.
forked from balena-io-experimental/balena-octoprint
-
Notifications
You must be signed in to change notification settings - Fork 23
/
Dockerfile.template
46 lines (35 loc) · 2.25 KB
/
Dockerfile.template
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
FROM --platform=linux/arm/v7 nunofgs/octoprint:master-alpine
# Install Raspberry Pi Libs and mDNS Prerequisites for PyBonjour
RUN apk update && apk add --no-cache avahi-compat-libdns_sd raspberrypi && \
ln -s /opt/vc/bin/* /usr/bin/
# Install build deps for various plugins, Octolapse for example. Should find a way for these to be conditionally installed in the Future.
RUN apk add --no-cache --virtual .build-deps \
zlib-dev \
jpeg-dev
# Install PyBonjour and Zeroconf
RUN pip install --no-cache-dir https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/pybonjour/pybonjour-1.1.1.tar.gz zeroconf
# Install eudev so we can use udevd properly
RUN apk update && apk add --no-cache eudev
# OctoDash requirements, it is stated these plugins are mandatory on the project wiki:
# https://github.com/UnchartedBull/OctoDash/wiki/Installation#automatic-installation
RUN PYTHONUSERBASE=/usr/local/ pip install --no-cache-dir \
"https://github.com/marian42/octoprint-preheat/archive/master.zip" \
"https://github.com/OllisGit/OctoPrint-DisplayLayerProgress/releases/latest/download/master.zip" \
"https://github.com/kantlivelong/OctoPrint-PSUControl/archive/master.zip" \
"https://github.com/OctoPrint/OctoPrint-MQTT/archive/master.zip" \
"https://github.com/malnvenshorn/OctoPrint-FilamentManager/archive/master.zip" \
"https://github.com/eyal0/OctoPrint-PrintTimeGenius/archive/master.zip" \
"https://github.com/jneilliii/OctoPrint-UltimakerFormatPackage/archive/master.zip" \
"https://github.com/jneilliii/OctoPrint-PrusaSlicerThumbnails/archive/master.zip" \
"https://github.com/vitormhenrique/OctoPrint-Enclosure/archive/master.zip"
# Adds support for obtaining OCTOPRINT_APIKEY and setting the octodash service variable automatically
# https://github.com/MatthewCroughan/octobalena/pull/10
RUN apk add --no-cache curl jq
COPY update-balena-app.sh /usr/src/octobalena/update-balena-app.sh
# Seed the initial config.yaml
COPY ./config.yaml /data/config.yaml
# Copy in the script that allows us to interface with espurna relays over mqtt
COPY ./mqtt_espurna_control.py /usr/src/octobalena/mqtt_espurna_control.py
COPY ./supervisord.conf /etc/supervisor/supervisord.conf
COPY ./udevd.sh /app/udevd.sh
CMD ["/app/udevd.sh"]