Skip to content

Commit

Permalink
More space-efficient models dockerfile (osrf#751)
Browse files Browse the repository at this point in the history
  • Loading branch information
peci1 authored Jan 13, 2021
1 parent 2f5dd1c commit 7dd2c0a
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions docker/subt_models/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,6 @@ RUN /bin/sh -c 'echo "deb [trusted=yes] http://packages.osrfoundation.org/gazebo
&& /bin/sh -c 'wget http://packages.osrfoundation.org/gazebo.key -O - | apt-key add -' \
&& /bin/sh -c 'apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654'

# install ign-dome
RUN apt-get update \
&& apt-get install -y \
ignition-dome \
&& apt-get clean

# Add a user with the same user_id as the user outside the container
# Requires a docker build argument `user_id`
ARG user_id
Expand All @@ -41,9 +35,11 @@ USER $USERNAME
# When running a container start in the developer's home folder
WORKDIR /home/$USERNAME

# Download the public models
RUN ign fuel download -v 4 -j 8 --type model -u "https://fuel.ignitionrobotics.org/OpenRobotics/collections/SubT Tech Repo"

# Cleanup ignition
RUN sudo apt-get remove ignition-dome -y \
# install ign-dome, download the public models, and uninstall ign-dome again to keep the image smaller
RUN sudo apt-get update \
&& sudo apt-get install -y \
libignition-fuel-tools5-dev \
&& ign fuel download -v 4 -j 8 --type model -u "https://fuel.ignitionrobotics.org/OpenRobotics/collections/SubT Tech Repo" \
&& sudo apt-get remove libignition-fuel-tools5-dev -y \
&& sudo apt-get autoremove -y \
&& sudo apt-get clean

0 comments on commit 7dd2c0a

Please sign in to comment.