-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
33 lines (26 loc) · 1.05 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
FROM ros:indigo-robot
LABEL mantainer="carlo.laviola@gmail.com"
# Install needed software
RUN apt-get update &&\
apt-get install -y \
build-essential \
ros-indigo-rosbridge-server \
ros-indigo-husky-simulator \
ros-indigo-husky-navigation \
ros-indigo-husky-desktop
# Copy our code from the current folder to /app inside the container
RUN mkdir /app
# Set up forwarding to use the GUI on the host machine
RUN export uid=1000 gid=1000 && \
mkdir -p /home/developer && \
echo "developer:x:${uid}:${gid}:Developer,,,:/home/developer:/bin/bash" >> /etc/passwd && \
echo "developer:x:${uid}:" >> /etc/group && \
echo "developer ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/developer && \
chmod 0440 /etc/sudoers.d/developer && \
chown ${uid}:${gid} -R /home/developer
WORKDIR /home/developer
# Change user and set up the environment variables
USER developer
ENV HOME=/home/developer
# Set up Husky simulator for the use case
ENV HUSKY_GAZEBO_DESCRIPTION=/opt/ros/indigo/share/husky_description/urdf/description.gazebo.xacro