Skip to content

Commit

Permalink
simplify the Dockerfile thanks to new husarion/ros images
Browse files Browse the repository at this point in the history
  • Loading branch information
DominikN committed Dec 29, 2023
1 parent 63389a4 commit e41fd94
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 159 deletions.
8 changes: 6 additions & 2 deletions Dockerfile.gazebo
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,13 @@ RUN apt-get update && apt-get install -y \
rm -rf src && \
rm -rf /var/lib/apt/lists/*

COPY ros_entrypoint.sh /
COPY vulcanexus_entrypoint.sh /
COPY healthcheck.sh /

HEALTHCHECK --interval=5s --timeout=2s --start-period=5s --retries=4 \
CMD ["/healthcheck.sh"]

RUN new_content1='source "/ros2_ws_healthcheck/install/setup.bash"' && \
new_content2='gosu $USER bash -c "ros2 run healthcheck_pkg healthcheck_node &"' && \
file=$(ls /*_entrypoint.sh | head -n 1) && \
sed -i "/exec/i $new_content1" $file && \
sed -i "/exec/i $new_content2" $file
7 changes: 3 additions & 4 deletions Dockerfile.hardware
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ RUN apt-get update && apt-get install -y \

COPY --from=cpu_id_builder /read_cpu_id/.pio/build/olimex_e407/firmware.bin /firmware_read_cpu_id.bin

COPY ros_entrypoint.sh /
COPY vulcanexus_entrypoint.sh /
COPY healthcheck.sh /

COPY print-serial-number.py /usr/bin/
Expand All @@ -138,5 +136,6 @@ HEALTHCHECK --interval=5s --timeout=2s --start-period=10s --retries=6 \

RUN new_content1='source "/ros2_ws_healthcheck/install/setup.bash"' && \
new_content2='gosu $USER bash -c "ros2 run healthcheck_pkg healthcheck_node &"' && \
sed -i "/exec/i $new_content1" /ros_entrypoint.sh && \
sed -i "/exec/i $new_content2" /ros_entrypoint.sh
file=$(ls /*_entrypoint.sh | head -n 1) && \
sed -i "/exec/i $new_content1" $file && \
sed -i "/exec/i $new_content2" $file
110 changes: 0 additions & 110 deletions flash-firmware.py

This file was deleted.

19 changes: 0 additions & 19 deletions ros_entrypoint.sh

This file was deleted.

24 changes: 0 additions & 24 deletions vulcanexus_entrypoint.sh

This file was deleted.

0 comments on commit e41fd94

Please sign in to comment.