-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile_modern_gpu
67 lines (54 loc) · 2.17 KB
/
Dockerfile_modern_gpu
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# Udacity capstone project dockerfile
#FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
FROM tensorflow/tensorflow:1.15.0-gpu
ARG DEBIAN_FRONTEND=noninteractive
ARG ROS_DISTRO=melodic
RUN apt-get update && \
apt-get install -y \
python \
python-pip \
lsb-release \
vim \
emacs25-nox \
nano \
git
RUN pip install --upgrade pip
RUN pip install --upgrade setuptools
RUN pip install --upgrade futures==3.1.1
RUN sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
RUN apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
RUN apt-get update && \
apt-get install -y ros-$ROS_DISTRO-desktop-full
RUN echo "source /opt/ros/${ROS_DISTRO}/setup.bash" >> ~/.bashrc
RUN apt-get install -y python-rosdep
RUN rosdep init && rosdep update
RUN apt-get install -y ros-$ROS_DISTRO-cv-bridge \
ros-$ROS_DISTRO-pcl-ros \
ros-$ROS_DISTRO-image-proc
# Install Dataspeed DBW https://goo.gl/KFSYi1 from binary
# adding Dataspeed server to apt
RUN sh -c 'echo "deb [ arch=amd64 ] http://packages.dataspeedinc.com/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-dataspeed-public.list'
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys FF6D3CDA
RUN apt-get update
# setup rosdep
RUN sh -c 'echo "yaml http://packages.dataspeedinc.com/ros/ros-public-'$ROS_DISTRO'.yaml '$ROS_DISTRO'" > /etc/ros/rosdep/sources.list.d/30-dataspeed-public-'$ROS_DISTRO'.list'
RUN rosdep update
RUN apt-get install -y ros-$ROS_DISTRO-dbw-mkz
#RUN apt-get upgrade -y
# end installing Dataspeed DBW
# install python packages
COPY requirements_modern_gpu.txt ./requirements_modern_gpu.txt
RUN pip install -r requirements_modern_gpu.txt
# install required ros dependencies
# socket io
RUN apt-get install -y netbase
RUN mkdir /capstone
VOLUME ["/capstone"]
VOLUME ["/root/.ros/log/"]
WORKDIR /capstone/ros
# port for simulator-ROS communication
EXPOSE 4567
# port for Jupyter notebook
EXPOSE 8888
COPY jupyter_notebook_config.py /root/.jupyter/
RUN apt-get -qq install libprotobuf-java protobuf-compiler