Skip to content

Commit 5fbdadf

Browse files
committed
add prereq
1 parent 5c3f74b commit 5fbdadf

File tree

2 files changed

+30
-20
lines changed

2 files changed

+30
-20
lines changed

.docker/jazzy.amd64.dockerfile

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,13 @@ RUN apt-get update && \
1212
lsb-release pkg-config protobuf-compiler \
1313
python3-dbg python3-pip python3-venv python3-pexpect \
1414
python-is-python3 python3-future python3-wxgtk4.0 \
15-
libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \
1615
qtbase5-dev ruby dirmngr gnupg2 nano xauth \
1716
software-properties-common htop libtool \
18-
x11-apps mesa-utils bison flex automake && \
19-
rm -rf /var/lib/apt/lists/
17+
x11-apps mesa-utils bison flex automake \
18+
libgz-sim8-dev rapidjson-dev libopencv-dev \
19+
libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \
20+
gstreamer1.0-plugins-bad gstreamer1.0-libav gstreamer1.0-gl \
21+
&& rm -rf /var/lib/apt/lists/
2022

2123
# Locale for UTF-8
2224
RUN truncate -s0 /tmp/preseed.cfg && \
@@ -50,7 +52,7 @@ extras/ardusub-ubuntu-install.sh install.sh
5052
RUN bash install.sh
5153

5254
# Set up Dave workspace
53-
ENV DAVE_WS=/opt/ws_dave
55+
ENV DAVE_WS=/opt/dave_ws
5456
WORKDIR $DAVE_WS/src
5557

5658
ADD https://raw.githubusercontent.com/IOES-Lab/dave/$BRANCH/\
@@ -69,25 +71,31 @@ RUN . "/opt/ros/${ROS_DISTRO}/setup.sh" && \
6971

7072
# source entrypoint setup
7173
RUN touch /ros_entrypoint.sh && sed --in-place --expression \
72-
'$i source "/opt/ws_dave/install/setup.bash"' /ros_entrypoint.sh
74+
'$i source "/opt/dave_ws/install/setup.bash"' /ros_entrypoint.sh
7375

7476
# Source ROS and Gazebo
7577
RUN sed --in-place --expression \
7678
'$i source "/opt/ros/jazzy/setup.bash"' /ros_entrypoint.sh && \
7779
sed --in-place --expression \
7880
'$i source "/opt/gazebo/install/setup.bash"' /ros_entrypoint.sh && \
7981
sed --in-place --expression \
80-
'$i export PYTHONPATH=$PYTHONPATH:/opt/gazebo/install/lib/python' /ros_entrypoint.sh && \
82+
'$i export PYTHONPATH=\$PYTHONPATH:/opt/gazebo/install/lib/python' /ros_entrypoint.sh && \
8183
sed --in-place --expression \
82-
'$i export PATH=/opt/ardupilot_dave/ardupilot/build/still/bin:$PATH' /ros_entrypoint.sh && \
84+
'$i export PATH=/opt/ardupilot_dave/ardupilot/build/still/bin:\$PATH' /ros_entrypoint.sh && \
8385
sed --in-place --expression \
84-
'$i export PATH=/opt/ardupilot_dave/ardupilot/Tools/autotest:$PATH' /ros_entrypoint.sh && \
86+
'$i export PATH=/opt/ardupilot_dave/ardupilot/Tools/autotest:\$PATH' /ros_entrypoint.sh && \
8587
sed --in-place --expression \
86-
'$i export GZ_SIM_SYSTEM_PLUGIN_PATH=/opt/ardupilot_dave/ardupilot_gazebo/build:$GZ_SIM_SYSTEM_PLUGIN_PATH' /ros_entrypoint.sh && \
88+
'$i export GZ_SIM_SYSTEM_PLUGIN_PATH=/opt/ardupilot_dave/ardupilot_gazebo/build:\$GZ_SIM_SYSTEM_PLUGIN_PATH' /ros_entrypoint.sh && \
8789
sed --in-place --expression \
88-
'$i export GZ_SIM_RESOURCE_PATH=/opt/ardupilot_dave/ardupilot_gazebo/models:/opt/ardupilot_dave/ardupilot_gazebo/worlds:$GZ_SIM_RESOURCE_PATH' /ros_entrypoint.sh
90+
'$i export GZ_SIM_RESOURCE_PATH=/opt/ardupilot_dave/ardupilot_gazebo/models:/opt/ardupilot_dave/ardupilot_gazebo/worlds:\$GZ_SIM_RESOURCE_PATH' /ros_entrypoint.sh
8991

9092
# Set User as user
9193
USER $USER
9294
RUN echo "source /opt/ros/jazzy/setup.bash" >> ~/.bashrc && \
93-
echo "source /opt/gazebo/install/setup.bash" >> ~/.bashrc
95+
echo "source /opt/gazebo/install/setup.bash" >> ~/.bashrc && \
96+
echo "export PYTHONPATH=\$PYTHONPATH:/opt/gazebo/install/lib/python" >> ~/.bashrc && \
97+
echo "export PATH=/opt/ardupilot_dave/ardupilot/build/still/bin:\$PATH" >> ~/.bashrc && \
98+
echo "export PATH=/opt/ardupilot_dave/ardupilot/Tools/autotest:\$PATH" >> ~/.bashrc && \
99+
echo "export GZ_SIM_SYSTEM_PLUGIN_PATH=/opt/ardupilot_dave/ardupilot_gazebo/build:\$GZ_SIM_SYSTEM_PLUGIN_PATH" >> ~/.bashrc && \
100+
echo "export GZ_SIM_RESOURCE_PATH=/opt/ardupilot_dave/ardupilot_gazebo/models:/opt/ardupilot_dave/ardupilot_gazebo/worlds:\$GZ_SIM_RESOURCE_PATH" >> ~/.bashrc
101+

.docker/jazzy.arm64v8.dockerfile

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@ RUN apt-get update && \
8989
apt-get install -y --no-install-recommends \
9090
python-is-python3 python3-future python3-wxgtk4.0 python3-pexpect \
9191
libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \
92+
libgz-sim8-dev rapidjson-dev libopencv-dev \
93+
gstreamer1.0-plugins-bad gstreamer1.0-libav gstreamer1.0-gl \
9294
&& rm -rf /var/lib/apt/lists/
9395

9496
# ROS-Gazebo arg
@@ -110,8 +112,8 @@ ENV ROS_UNDERLAY=/home/$USER/dave_ws/install
110112
WORKDIR $ROS_UNDERLAY/../src
111113

112114
ADD https://raw.githubusercontent.com/IOES-Lab/dave/$BRANCH/\
113-
extras/repos/dave.$ROS_DISTRO.repos /home/$USER/ws_dave/dave.repos
114-
RUN vcs import --shallow --input "/home/$USER/ws_dave/dave.repos"
115+
extras/repos/dave.$ROS_DISTRO.repos /home/$USER/dave_ws/dave.repos
116+
RUN vcs import --shallow --input "/home/$USER/dave_ws/dave.repos"
115117

116118
RUN rosdep init && \
117119
rosdep update --rosdistro $ROS_DISTRO
@@ -145,13 +147,13 @@ RUN touch /ros_entrypoint.sh && sed --in-place --expression \
145147
USER docker
146148
RUN echo "source /opt/ros/jazzy/setup.bash" >> ~/.bashrc && \
147149
echo "source /opt/gazebo/install/setup.bash" >> ~/.bashrc && \
148-
echo "export PYTHONPATH=$PYTHONPATH:/opt/gazebo/install/lib/python" >> ~/.bashrc && \
149-
echo "export PATH=/opt/ardupilot_dave/ardupilot/build/still/bin:$PATH" >> ~/.bashrc && \
150-
echo "export PATH=/opt/ardupilot_dave/ardupilot/Tools/autotest:$PATH" >> ~/.bashrc && \
151-
echo "export GZ_SIM_SYSTEM_PLUGIN_PATH=/opt/ardupilot_dave/ardupilot_gazebo/build:$GZ_SIM_SYSTEM_PLUGIN_PATH" >> ~/.bashrc && \
152-
echo "export GZ_SIM_RESOURCE_PATH=/opt/ardupilot_dave/ardupilot_gazebo/models:/opt/ardupilot_dave/ardupilot_gazebo/worlds:$GZ_SIM_RESOURCE_PATH" >> ~/.bashrc && \
153-
echo "if [ -d ~/HOST ]; then chown docker:docker ~/HOST; fi" \
154-
>> ~/.bashrc
150+
echo "export PYTHONPATH=\$PYTHONPATH:/opt/gazebo/install/lib/python" >> ~/.bashrc && \
151+
echo "export PATH=/opt/ardupilot_dave/ardupilot/build/still/bin:\$PATH" >> ~/.bashrc && \
152+
echo "export PATH=/opt/ardupilot_dave/ardupilot/Tools/autotest:\$PATH" >> ~/.bashrc && \
153+
echo "export GZ_SIM_SYSTEM_PLUGIN_PATH=/opt/ardupilot_dave/ardupilot_gazebo/build:\$GZ_SIM_SYSTEM_PLUGIN_PATH" >> ~/.bashrc && \
154+
echo "export GZ_SIM_RESOURCE_PATH=/opt/ardupilot_dave/ardupilot_gazebo/models:/opt/ardupilot_dave/ardupilot_gazebo/worlds:\$GZ_SIM_RESOURCE_PATH" >> ~/.bashrc && \&& \
155+
echo "\n\n" >> ~/.bashrc && echo "if [ -d ~/HOST ]; then chown docker:docker ~/HOST; fi" >> ~/.bashrc && \
156+
echo "\n\n" >> ~/.bashrc
155157

156158
# Other environment variables
157159
RUN echo "export XDG_RUNTIME_DIR=~/.xdg_log" >> ~/.bashrc && \

0 commit comments

Comments
 (0)