Last active
October 24, 2017 22:32
-
-
Save MisterRager/45dd2f7cf5c6bfb2ed8c92223dc43e91 to your computer and use it in GitHub Desktop.
m33 Fio Dockerfile: octoprint + m3d control extension in a Docker container
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:xenial | |
RUN apt-get update && apt-get install -y \ | |
wget \ | |
unzip \ | |
sudo \ | |
python \ | |
python-setuptools \ | |
python-dev \ | |
build-essential | |
ENV INSTALLER_URL https://raw.githubusercontent.com/donovan6000/M33-Fio/master/installers/Linux/install.zip | |
RUN cd /tmp && wget --quiet ${INSTALLER_URL} | |
RUN cd /tmp && unzip -q install.zip -d . | |
RUN mkdir -p /etc/udev/rules.d | |
ENV SUDO_USER octoprint | |
RUN useradd -m -G dialout,tty ${SUDO_USER} && echo "${SUDO_USER} ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers.d/${SUDO_USER} | |
#INSTALL octoprint + m33-fio | |
RUN su -c /tmp/install.sh ${SUDO_USER} && cd /home/${SUDO_USER}/.local/bin | |
RUN /bin/rm /tmp/install.sh /tmp/install.zip /etc/sudoers.d/${SUDO_USER} | |
#INSTALL cura-engine | |
RUN sudo -iu ${SUDO_USER} && cd /home/${SUDO_USER} && git clone https://github.com/Ultimaker/CuraEngine.git && cd CuraEngine && git checkout 15.04.6 && make | |
EXPOSE 5000 | |
CMD sudo -iu ${SUDO_USER} /home/${SUDO_USER}/.local/bin/octoprint serve |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
docker build -t octoprint-m3d-image . | |
docker run -d -p 5000:5000 --privileged -v /dev:/dev octoprint-m3d-image |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment