Last active
March 8, 2021 05:46
-
-
Save atinfinity/c3255077e23164438c19544687e05b84 to your computer and use it in GitHub Desktop.
depthai Dockerfile(does not work)
This file contains 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:18.04 | |
# add new sudo user | |
ENV USERNAME depthai | |
ENV HOME /home/$USERNAME | |
RUN useradd -m $USERNAME && \ | |
echo "$USERNAME:$USERNAME" | chpasswd && \ | |
usermod --shell /bin/bash $USERNAME && \ | |
usermod -aG sudo $USERNAME && \ | |
mkdir /etc/sudoers.d && \ | |
echo "$USERNAME ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/$USERNAME && \ | |
chmod 0440 /etc/sudoers.d/$USERNAME && \ | |
# Replace 1000 with your user/group id | |
usermod --uid 1000 $USERNAME && \ | |
groupmod --gid 1000 $USERNAME | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN apt-get update && apt-get install -y --no-install-recommends \ | |
sudo \ | |
less \ | |
emacs \ | |
build-essential \ | |
cmake \ | |
git \ | |
tmux \ | |
bash-completion \ | |
command-not-found \ | |
software-properties-common \ | |
xsel \ | |
xdg-user-dirs \ | |
wget \ | |
curl \ | |
usbutils \ | |
udev \ | |
&& \ | |
apt-get clean && \ | |
rm -rf /var/lib/apt/lists/* | |
# https://github.com/luxonis/depthai-docker/blob/master/Dockerfile-depthai#L11 | |
RUN echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="03e7", MODE="0666"' | tee /etc/udev/rules.d/80-movidius.rules | |
USER $USERNAME | |
WORKDIR /home/${USERNAME} | |
SHELL ["/bin/bash", "-c"] | |
RUN sudo wget -qO- http://docs.luxonis.com/_static/install_dependencies.sh | bash | |
RUN git clone https://github.com/luxonis/depthai.git -b v0.4.0.0 && \ | |
cd depthai && \ | |
python3 install_requirements.py |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Host
Docker Container