Skip to content

Commit

Permalink
Merge pull request #6 from ika-rwth-aachen/fix/gitlab-single-target
Browse files Browse the repository at this point in the history
Fix failing push stage in case of single target on gitlab
  • Loading branch information
jpbusch authored Jul 8, 2023
2 parents 49d3bac + 92cd970 commit e7f4ae3
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
16 changes: 8 additions & 8 deletions .gitlab-ci/docker-ros.yml
Original file line number Diff line number Diff line change
Expand Up @@ -250,18 +250,18 @@ Test run-arm64:
script:
- |-
if [[ "${PLATFORM}" =~ amd64 && "${PLATFORM}" =~ arm64 ]]; then
[[ "${TARGET}" =~ dev ]] && docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_AMD64} --amend ${_IMAGE_DEV_CI_ARM64}
[[ "${TARGET}" =~ run ]] && docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_AMD64} --amend ${_IMAGE_RUN_CI_ARM64}
if [[ "${TARGET}" =~ dev ]]; then docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_AMD64} --amend ${_IMAGE_DEV_CI_ARM64}; fi
if [[ "${TARGET}" =~ run ]]; then docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_AMD64} --amend ${_IMAGE_RUN_CI_ARM64}; fi
elif [[ "${PLATFORM}" =~ amd64 ]]; then
[[ "${TARGET}" =~ dev ]] && docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_AMD64}
[[ "${TARGET}" =~ run ]] && docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_AMD64}
if [[ "${TARGET}" =~ dev ]]; then docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_AMD64}; fi
if [[ "${TARGET}" =~ run ]]; then docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_AMD64}; fi
elif [[ "${PLATFORM}" =~ arm64 ]]; then
[[ "${TARGET}" =~ dev ]] && docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_ARM64}
[[ "${TARGET}" =~ run ]] && docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_ARM64}
if [[ "${TARGET}" =~ dev ]]; then docker manifest create ${IMG_DEV} --amend ${_IMAGE_DEV_CI_ARM64}; fi
if [[ "${TARGET}" =~ run ]]; then docker manifest create ${IMG_RUN} --amend ${_IMAGE_RUN_CI_ARM64}; fi
fi
- |-
[[ "${TARGET}" =~ dev ]] && docker manifest push ${IMG_DEV}
[[ "${TARGET}" =~ run ]] && docker manifest push ${IMG_RUN}
if [[ "${TARGET}" =~ dev ]]; then docker manifest push ${IMG_DEV}; fi
if [[ "${TARGET}" =~ run ]]; then docker manifest push ${IMG_RUN}; fi
Push CI:
stage: Push Multi-Arch Images
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ jobs:
docker-ros:
runs-on: ubuntu-latest
steps:
- uses: ika-rwth-aachen/[email protected].2
- uses: ika-rwth-aachen/[email protected].3
with:
base-image: rwthika/ros2:humble
command: ros2 run my_pkg my_node
Expand All @@ -110,7 +110,7 @@ jobs:
```yml
include:
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.2/.gitlab-ci/docker-ros.yml
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.3/.gitlab-ci/docker-ros.yml

variables:
BASE_IMAGE: rwthika/ros2:humble
Expand All @@ -129,7 +129,7 @@ jobs:
docker-ros:
runs-on: ubuntu-latest
steps:
- uses: ika-rwth-aachen/[email protected].2
- uses: ika-rwth-aachen/[email protected].3
with:
base-image: rwthika/ros2:humble
command: ros2 run my_pkg my_node
Expand All @@ -142,7 +142,7 @@ jobs:
```yml
include:
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.2/.gitlab-ci/docker-ros.yml
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.3/.gitlab-ci/docker-ros.yml

variables:
BASE_IMAGE: rwthika/ros2:humble
Expand All @@ -162,7 +162,7 @@ jobs:
docker-ros:
runs-on: ubuntu-latest
steps:
- uses: ika-rwth-aachen/[email protected].2
- uses: ika-rwth-aachen/[email protected].3
with:
base-image: rwthika/ros2:humble
command: ros2 run my_pkg my_node
Expand All @@ -176,7 +176,7 @@ jobs:
```yml
include:
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.2/.gitlab-ci/docker-ros.yml
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.3/.gitlab-ci/docker-ros.yml

variables:
BASE_IMAGE: rwthika/ros2:humble
Expand All @@ -197,7 +197,7 @@ jobs:
docker-ros:
runs-on: ubuntu-latest
steps:
- uses: ika-rwth-aachen/[email protected].2
- uses: ika-rwth-aachen/[email protected].3
with:
base-image: rwthika/ros2:humble
command: ros2 run my_pkg my_node
Expand All @@ -210,7 +210,7 @@ jobs:
```yml
include:
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.2/.gitlab-ci/docker-ros.yml
- remote: https://raw.githubusercontent.com/ika-rwth-aachen/docker-ros/v1.2.3/.gitlab-ci/docker-ros.yml

variables:
BASE_IMAGE: rwthika/ros2:humble
Expand All @@ -234,7 +234,7 @@ jobs:
platform: [amd64, arm64]
runs-on: [self-hosted, "${{ matrix.platform }}"]
steps:
- uses: ika-rwth-aachen/[email protected].2
- uses: ika-rwth-aachen/[email protected].3
with:
base-image: rwthika/ros2:humble
command: ros2 run my_pkg my_node
Expand Down

0 comments on commit e7f4ae3

Please sign in to comment.