docker cleanup

This commit is contained in:
matlabbe
2023-02-04 17:41:07 -08:00
parent 413be8e824
commit 5fd0448924
4 changed files with 56 additions and 28 deletions
+12 -6
View File
@@ -4,15 +4,21 @@ FROM ros:melodic-perception
# Install build dependencies # Install build dependencies
RUN apt-get update && \ RUN apt-get update && \
apt-get install -y git software-properties-common ros-melodic-rtabmap-ros libmrpt-dev && \ apt-get install -y git software-properties-common ros-melodic-rtabmap-ros && \
apt-get remove -y ros-melodic-rtabmap && \ apt-get remove -y ros-melodic-rtabmap && \
rm -rf /var/lib/apt/lists/ apt-get clean && rm -rf /var/lib/apt/lists/
WORKDIR /root/ WORKDIR /root/
# GTSAM # GTSAM
RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y
RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
# MRPT
RUN add-apt-repository ppa:joseluisblancoc/mrpt-stable -y
RUN apt-get update && apt install libmrpt-poses-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
ARG TARGETPLATFORM ARG TARGETPLATFORM
ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64} ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64}
@@ -22,7 +28,7 @@ RUN echo "I am building for $TARGETPLATFORM"
RUN if [ "$TARGETPLATFORM" = "linux/arm64" ]; then ln -s /usr/bin/cmake ~/cmake; fi RUN if [ "$TARGETPLATFORM" = "linux/arm64" ]; then ln -s /usr/bin/cmake ~/cmake; fi
# cmake >=3.11 required for amd64 dependencies # cmake >=3.11 required for amd64 dependencies
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then apt install -y wget && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then apt update && apt install -y wget && apt-get clean && rm -rf /var/lib/apt/lists/ && \
wget -nv https://github.com/Kitware/CMake/releases/download/v3.17.0/cmake-3.17.0-Linux-x86_64.tar.gz && \ wget -nv https://github.com/Kitware/CMake/releases/download/v3.17.0/cmake-3.17.0-Linux-x86_64.tar.gz && \
tar -xzf cmake-3.17.0-Linux-x86_64.tar.gz && \ tar -xzf cmake-3.17.0-Linux-x86_64.tar.gz && \
rm cmake-3.17.0-Linux-x86_64.tar.gz &&\ rm cmake-3.17.0-Linux-x86_64.tar.gz &&\
@@ -33,7 +39,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then apt-get update && DEBIAN_FRON
libsuitesparse-dev \ libsuitesparse-dev \
libceres-dev \ libceres-dev \
xorg-dev \ xorg-dev \
libglu1-mesa-dev; fi libglu1-mesa-dev && apt-get clean && rm -rf /var/lib/apt/lists/; fi
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \
cd oiio && \ cd oiio && \
git checkout Release-2.0.12 && \ git checkout Release-2.0.12 && \
@@ -80,7 +86,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/
rm -r AliceVision; fi rm -r AliceVision; fi
#commit Aug 6 2020 #commit Aug 6 2020
RUN apt-get update && apt install wget RUN apt-get update && apt install wget && apt-get clean && rm -rf /var/lib/apt/lists/
RUN git clone https://github.com/laurentkneip/opengv.git && \ RUN git clone https://github.com/laurentkneip/opengv.git && \
cd opengv && \ cd opengv && \
git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \ git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \
+17 -8
View File
@@ -5,23 +5,28 @@ FROM osrf/ros:foxy-desktop
# Install build dependencies # Install build dependencies
RUN apt-get update && \ RUN apt-get update && \
apt-get install -y git software-properties-common ros-foxy-rtabmap-ros && \ apt-get install -y git software-properties-common ros-foxy-rtabmap-ros && \
apt-get remove -y ros-foxy-rtabmap apt-get remove -y ros-foxy-rtabmap && \
apt-get clean && rm -rf /var/lib/apt/lists/
WORKDIR /root/ WORKDIR /root/
# GTSAM # GTSAM
RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y
RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
# MRPT # MRPT
RUN add-apt-repository ppa:joseluisblancoc/mrpt-stable -y RUN add-apt-repository ppa:joseluisblancoc/mrpt-stable -y
RUN apt-get update && apt install libmrpt-poses-dev -y RUN apt-get update && apt install libmrpt-poses-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
# PDAL # PDAL
RUN apt-get install -y libpdal-dev RUN apt-get update && apt-get install -y libpdal-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/
# RealSense2 # RealSense2
RUN apt-get install -y ros-foxy-librealsense2 RUN apt-get update && apt-get install -y ros-foxy-librealsense2 && \
apt-get clean && rm -rf /var/lib/apt/lists/
ARG TARGETPLATFORM ARG TARGETPLATFORM
ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64} ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64}
@@ -53,11 +58,13 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing k4a..." && \
dpkg -i /tmp/libk4abt1.0-dev_1.0.0_amd64.deb && \ dpkg -i /tmp/libk4abt1.0-dev_1.0.0_amd64.deb && \
apt-get install -y libsoundio1 && \ apt-get install -y libsoundio1 && \
dpkg -i /tmp/k4a-tools_1.3.0_amd64.deb && \ dpkg -i /tmp/k4a-tools_1.3.0_amd64.deb && \
rm /tmp/libk4a* /tmp/k4a*; fi rm /tmp/libk4a* /tmp/k4a* && \
apt-get clean && rm -rf /var/lib/apt/lists/; fi
# libfreenect2 # libfreenect2
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \
apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \ apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/OpenKinect/libfreenect2 && \ git clone https://github.com/OpenKinect/libfreenect2 && \
cd libfreenect2 && \ cd libfreenect2 && \
mkdir build && \ mkdir build && \
@@ -71,6 +78,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2
# zed open capture # zed open capture
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \
apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \ apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/stereolabs/zed-open-capture.git && \ git clone https://github.com/stereolabs/zed-open-capture.git && \
cd zed-open-capture && \ cd zed-open-capture && \
mkdir build && \ mkdir build && \
@@ -88,7 +96,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing AliceVision.
libceres-dev \ libceres-dev \
xorg-dev \ xorg-dev \
libglu1-mesa-dev \ libglu1-mesa-dev \
wget; fi wget && apt-get clean && rm -rf /var/lib/apt/lists/; fi
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \
cd oiio && \ cd oiio && \
git checkout Release-2.0.12 && \ git checkout Release-2.0.12 && \
@@ -135,7 +143,8 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/
rm -r AliceVision; fi rm -r AliceVision; fi
#commit Aug 6 2020 #commit Aug 6 2020
RUN apt-get update && apt install wget RUN apt-get update && apt install wget && \
apt-get clean && rm -rf /var/lib/apt/lists/
RUN git clone https://github.com/laurentkneip/opengv.git && \ RUN git clone https://github.com/laurentkneip/opengv.git && \
cd opengv && \ cd opengv && \
git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \ git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \
+16 -9
View File
@@ -6,23 +6,27 @@ FROM ros:noetic-perception
RUN apt-get update && \ RUN apt-get update && \
apt-get install -y git software-properties-common ros-noetic-rtabmap-ros && \ apt-get install -y git software-properties-common ros-noetic-rtabmap-ros && \
apt-get remove -y ros-noetic-rtabmap && \ apt-get remove -y ros-noetic-rtabmap && \
rm -rf /var/lib/apt/lists/ apt-get clean && rm -rf /var/lib/apt/lists/
WORKDIR /root/ WORKDIR /root/
# GTSAM # GTSAM
RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y RUN add-apt-repository ppa:borglab/gtsam-release-4.0 -y
RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y RUN apt-get update && apt install libgtsam-dev libgtsam-unstable-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
#MRPT # MRPT
RUN add-apt-repository ppa:joseluisblancoc/mrpt-stable -y RUN add-apt-repository ppa:joseluisblancoc/mrpt-stable -y
RUN apt-get update && apt install libmrpt-poses-dev -y RUN apt-get update && apt install libmrpt-poses-dev -y && \
apt-get clean && rm -rf /var/lib/apt/lists/
# PDAL # PDAL
RUN apt-get install -y libpdal-dev RUN apt-get update && apt-get install -y libpdal-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/
# RealSense2 # RealSense2
RUN apt-get install -y ros-noetic-librealsense2 RUN apt-get update && apt-get install -y ros-noetic-librealsense2 && \
apt-get clean && rm -rf /var/lib/apt/lists/
ARG TARGETPLATFORM ARG TARGETPLATFORM
ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64} ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64}
@@ -54,11 +58,13 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing k4a..." && \
dpkg -i /tmp/libk4abt1.0-dev_1.0.0_amd64.deb && \ dpkg -i /tmp/libk4abt1.0-dev_1.0.0_amd64.deb && \
apt-get install -y libsoundio1 && \ apt-get install -y libsoundio1 && \
dpkg -i /tmp/k4a-tools_1.3.0_amd64.deb && \ dpkg -i /tmp/k4a-tools_1.3.0_amd64.deb && \
rm /tmp/libk4a* /tmp/k4a*; fi rm /tmp/libk4a* /tmp/k4a* && \
apt-get clean && rm -rf /var/lib/apt/lists/; fi
# libfreenect2 # libfreenect2
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \
apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \ apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/OpenKinect/libfreenect2 && \ git clone https://github.com/OpenKinect/libfreenect2 && \
cd libfreenect2 && \ cd libfreenect2 && \
mkdir build && \ mkdir build && \
@@ -72,6 +78,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2
# zed open capture # zed open capture
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \
apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \ apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/stereolabs/zed-open-capture.git && \ git clone https://github.com/stereolabs/zed-open-capture.git && \
cd zed-open-capture && \ cd zed-open-capture && \
mkdir build && \ mkdir build && \
@@ -89,7 +96,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing AliceVision.
libceres-dev \ libceres-dev \
xorg-dev \ xorg-dev \
libglu1-mesa-dev \ libglu1-mesa-dev \
wget; fi wget && apt-get clean && rm -rf /var/lib/apt/lists/; fi
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/OpenImageIO/oiio.git && \
cd oiio && \ cd oiio && \
git checkout Release-2.0.12 && \ git checkout Release-2.0.12 && \
@@ -136,7 +143,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then git clone https://github.com/
rm -r AliceVision; fi rm -r AliceVision; fi
#commit Aug 6 2020 #commit Aug 6 2020
RUN apt-get update && apt install wget RUN apt-get update && apt install wget && apt-get clean && rm -rf /var/lib/apt/lists/
RUN git clone https://github.com/laurentkneip/opengv.git && \ RUN git clone https://github.com/laurentkneip/opengv.git && \
cd opengv && \ cd opengv && \
git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \ git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \
+11 -5
View File
@@ -4,16 +4,19 @@ FROM osrf/ros:humble-desktop
# Install build dependencies # Install build dependencies
RUN apt-get update && \ RUN apt-get update && \
apt-get install -y git software-properties-common ros-humble-rtabmap-ros libmrpt-poses-dev && \ apt-get install -y git software-properties-common ros-humble-rtabmap-ros && \
apt-get remove -y ros-humble-rtabmap apt-get remove -y ros-humble-rtabmap && \
apt-get clean && rm -rf /var/lib/apt/lists/
WORKDIR /root/ WORKDIR /root/
# PDAL # PDAL
RUN apt-get install -y libpdal-dev RUN apt-get update && apt-get install -y libpdal-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/
# RealSense2 # RealSense2
RUN apt-get install -y ros-humble-librealsense2 RUN apt-get update && apt-get install -y ros-humble-librealsense2 && \
apt-get clean && rm -rf /var/lib/apt/lists/
ARG TARGETPLATFORM ARG TARGETPLATFORM
ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64} ENV TARGETPLATFORM=${TARGETPLATFORM:-linux/amd64}
@@ -24,6 +27,7 @@ ENV DEBIAN_FRONTEND=noninteractive
# libfreenect2 # libfreenect2
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2..." && \
apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \ apt-get update && apt-get install -y mesa-utils xserver-xorg-video-all libusb-1.0-0-dev libturbojpeg0-dev libglfw3-dev && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/OpenKinect/libfreenect2 && \ git clone https://github.com/OpenKinect/libfreenect2 && \
cd libfreenect2 && \ cd libfreenect2 && \
mkdir build && \ mkdir build && \
@@ -37,6 +41,7 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing libfreenect2
# zed open capture # zed open capture
RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-capture..." && \
apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \ apt-get update && apt install libusb-1.0-0-dev libhidapi-libusb0 libhidapi-dev wget && \
apt-get clean && rm -rf /var/lib/apt/lists/ && \
git clone https://github.com/stereolabs/zed-open-capture.git && \ git clone https://github.com/stereolabs/zed-open-capture.git && \
cd zed-open-capture && \ cd zed-open-capture && \
mkdir build && \ mkdir build && \
@@ -48,7 +53,8 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then echo "Installing zed-open-cap
rm -r zed-open-capture; fi rm -r zed-open-capture; fi
#commit Aug 6 2020 #commit Aug 6 2020
RUN apt-get update && apt install wget RUN apt-get update && apt install wget && \
apt-get clean && rm -rf /var/lib/apt/lists/
RUN git clone https://github.com/laurentkneip/opengv.git && \ RUN git clone https://github.com/laurentkneip/opengv.git && \
cd opengv && \ cd opengv && \
git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \ git checkout 91f4b19c73450833a40e463ad3648aae80b3a7f3 && \