forked from bpinaya/robond-docker
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Dockerfile
37 lines (28 loc) · 1.47 KB
/
Dockerfile
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
# Kudos to DOROWU for his amazing VNC 18.04 LXDE image
FROM dorowu/ubuntu-desktop-lxde-vnc:bionic
LABEL maintainer "[email protected]"
# Fix dirmngr
RUN sudo apt purge dirmngr -y && sudo apt update && sudo apt install dirmngr -y
# Adding keys for ROS
RUN sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
RUN sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
# Installing ROS
RUN sudo apt-get update && sudo apt-get install -y ros-melodic-desktop-full \
wget git nano
RUN rosdep init && rosdep update
RUN /bin/bash -c "echo 'export HOME=/home/ubuntu' >> /root/.bashrc && source /root/.bashrc"
# Creating ROS_WS
RUN mkdir -p ~/ros_ws/src
# Set up the workspace
RUN /bin/bash -c "source /opt/ros/melodic/setup.bash && \
cd ~/ros_ws/ && \
catkin_make && \
echo 'source ~/ros_ws/devel/setup.bash' >> ~/.bashrc && \
echo 'source ~/ros_ws/devel/setup.bash' >> /root/.bashrc "
RUN sudo apt install -y python-rosinstall python-rosinstall-generator python-wstool build-essential
# Updating ROSDEP and installing dependencies
#RUN cd ~/ros_ws && rosdep update && rosdep install --from-paths src --ignore-src --rosdistro=kinetic -y
# Sourcing
RUN /bin/bash -c "source /opt/ros/melodic/setup.bash && \
cd ~/ros_ws/ && rm -rf build devel && \
catkin_make"