Skip to content
Snippets Groups Projects
Commit 05a6bdfc authored by Montaño Sarria, Andres Felipe's avatar Montaño Sarria, Andres Felipe
Browse files

Fix remove lists to reduce image size

parent 41e0f628
No related branches found
No related tags found
No related merge requests found
...@@ -60,7 +60,8 @@ RUN apt-get update && \ ...@@ -60,7 +60,8 @@ RUN apt-get update && \
trash-cli \ trash-cli \
valgrind \ valgrind \
wget \ wget \
xterm xterm \
&& rm -rf /var/lib/apt/lists/*
# Install zsh if requested # Install zsh if requested
RUN if [ "$EXT_SHELL" = "zsh" ]; \ RUN if [ "$EXT_SHELL" = "zsh" ]; \
...@@ -90,7 +91,7 @@ RUN if [ -f "${ROS_DISTRO}_requirements.txt" ]; \ ...@@ -90,7 +91,7 @@ RUN if [ -f "${ROS_DISTRO}_requirements.txt" ]; \
# workaround for ROS jazzy # workaround for ROS jazzy
export PIP_BREAK_SYSTEM_PACKAGES=1 && \ export PIP_BREAK_SYSTEM_PACKAGES=1 && \
awk '/^# PIP PACKAGES/,0' ${ROS_DISTRO}_requirements.txt | grep -v '^#' | xargs -r -n1 pip install -U ;\ awk '/^# PIP PACKAGES/,0' ${ROS_DISTRO}_requirements.txt | grep -v '^#' | xargs -r -n1 pip install -U ;\
apt-get clean; \ apt-get clean; rm -rf /var/lib/apt/lists/*; \
fi fi
# Install extra libs from .deb files # Install extra libs from .deb files
...@@ -107,14 +108,15 @@ RUN if [ -f "common_libs.txt" ]; \ ...@@ -107,14 +108,15 @@ RUN if [ -f "common_libs.txt" ]; \
fi fi
# Install notify-osd # Install notify-osd
RUN apt-get --reinstall install -y libnotify-bin notify-osd RUN apt-get update && apt-get --reinstall install -y libnotify-bin notify-osd
RUN rm -rf * RUN rm -rf *
# Update base image # Update base image
RUN apt-get update \ RUN apt-get update \
&& apt-get -y upgrade \ && apt-get -y upgrade \
&& apt-get -y autoremove \ && apt-get -y autoremove \
&& apt-get -y autoclean && apt-get -y autoclean \
&& rm -rf /var/lib/apt/lists/*
# Copy entrypoint # Copy entrypoint
COPY ./ros_entrypoint.sh / COPY ./ros_entrypoint.sh /
...@@ -180,6 +182,7 @@ RUN if [ "$PEAK_DRIVER" = "install" ]; \ ...@@ -180,6 +182,7 @@ RUN if [ "$PEAK_DRIVER" = "install" ]; \
&& tar -xvf PCAN-Basic_Linux.tar.gz \ && tar -xvf PCAN-Basic_Linux.tar.gz \
&& cd PCAN-Basic_Linux-4.9.0.7/libpcanbasic \ && cd PCAN-Basic_Linux-4.9.0.7/libpcanbasic \
&& make clean && make install || echo 'make failed but move forward';\ && make clean && make install || echo 'make failed but move forward';\
rm -rf /var/lib/apt/lists/*; \
fi fi
# Install conan for Kortex driver # Install conan for Kortex driver
...@@ -212,7 +215,8 @@ LABEL image.date=09-01-2025 ...@@ -212,7 +215,8 @@ LABEL image.date=09-01-2025
RUN apt-get update \ RUN apt-get update \
&& apt-get -y upgrade \ && apt-get -y upgrade \
&& apt-get -y autoremove \ && apt-get -y autoremove \
&& apt-get -y autoclean && apt-get -y autoclean \
&& rm -rf /var/lib/apt/lists/*
# Switch back to dialog for any ad-hoc use of apt-get # Switch back to dialog for any ad-hoc use of apt-get
ENV DEBIAN_FRONTEND= ENV DEBIAN_FRONTEND=
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment