Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Touchup Dockerfile and create a workflow building it #323

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/humble-docker-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Build Humble Dockerfile
# description: builds the dockerfile contained within the repo

on:
pull_request:
branches:
- humble
push:
branches:
- humble
schedule:
# Run every morning to detect broken dependencies
- cron: '40 1 * * *'


jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile/Dockerfile --tag ros2_control_demos_humble
5 changes: 0 additions & 5 deletions .github/workflows/rolling-binary-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@ on:
# Run every morning to detect flakiness and broken dependencies
- cron: '03 1 * * *'

#TODO(christophfroehlich): remove once it is released
# otherwise ros-gz won't build
env:
GZ_VERSION: fortress

jobs:
binary:
uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/rolling-docker-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Build Rolling Dockerfile
# description: builds the dockerfile contained within the repo

on:
pull_request:
branches:
- master
push:
branches:
- master
schedule:
# Run every morning to detect broken dependencies
- cron: '50 1 * * *'


jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile/Dockerfile --tag ros2_control_demos_rolling
16 changes: 13 additions & 3 deletions Dockerfile/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,23 @@ FROM ros:${ROS_DISTRO}-ros-base
ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update \
&& apt-get upgrade -y
&& apt-get upgrade -y \
&& \
: "remove cache" && \
apt-get autoremove -y -qq && \
rm -rf /var/lib/apt/lists/*

COPY . /home/ros2_ws/src/ros2_control_demos

RUN cd /home/ros2_ws/src \
&& rosdep update \
&& rosdep install --from-paths ./ -i -y --rosdistro ${ROS_DISTRO} --skip-keys rviz2
&& rosdep update --rosdistro ${ROS_DISTRO} \
&& apt-get update \
&& rosdep install --from-paths ./ -i -y --rosdistro ${ROS_DISTRO} \
--skip-keys ros-${ROS_DISTRO}-joint-state-publisher-gui --skip-keys ros-${ROS_DISTRO}-rviz2\
&& \
: "remove cache" && \
apt-get autoremove -y -qq && \
rm -rf /var/lib/apt/lists/*

RUN cd /home/ros2_ws/ \
&& . /opt/ros/${ROS_DISTRO}/setup.sh \
Expand Down