-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/RJD-1057-remove-functions-forwar…
…ded-to-entity-base-refactor' into ref/RJD-1057-improve-responsibility-simulator-core-api
- Loading branch information
Showing
243 changed files
with
33,891 additions
and
2,751 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
name: Docker | ||
on: | ||
pull_request: | ||
paths: | ||
- "**" | ||
- "!docs/**" | ||
- "!README.md" | ||
- "!CONTRIBUTING.md" | ||
- "!.github/**" | ||
- ".github/workflows/Docker.yaml" | ||
- "!mkdocs.yml" | ||
- "!pyproject.toml" | ||
- "!poetry.lock" | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
description: version of the scenario_simulator_v2 | ||
required: true | ||
|
||
jobs: | ||
push_docker: | ||
name: Push Docker Image | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 720 | ||
strategy: | ||
matrix: | ||
rosdistro: [humble] | ||
arch: [amd64] | ||
# Build test for arm64 CPU is broken. | ||
# This is a temporary solution and will be repaired in the future. | ||
# See also https://github.com/tier4/scenario_simulator_v2/pull/1295 | ||
# arch: [amd64, arm64] | ||
steps: | ||
- name: Free Disk Space (Ubuntu) | ||
uses: jlumbroso/free-disk-space@main | ||
with: | ||
tool-cache: false | ||
|
||
- name: Install docker for ubuntu runner | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Install QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
|
||
- uses: actions/checkout@v4 | ||
|
||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build (${{ matrix.arch }}) | ||
if: github.event_name == 'pull_request' | ||
uses: docker/bake-action@v3 | ||
with: | ||
files: | | ||
./docker-bake.hcl | ||
workdir: . | ||
set: | | ||
*.cache-to=type=gha,mode=max | ||
*.cache-from=type=gha | ||
push: false | ||
targets: | | ||
${{ matrix.rosdistro }}_base_${{ matrix.arch }} | ||
- name: Build and push (${{ matrix.arch }}) | ||
if: github.event_name == 'workflow_dispatch' | ||
uses: docker/bake-action@v3 | ||
with: | ||
files: | | ||
./docker-bake.hcl | ||
workdir: . | ||
set: | | ||
*.cache-to=type=gha,mode=max | ||
*.cache-from=type=gha | ||
*.tags=ghcr.io/tier4/scenario_simulator_v2:humble-${{ github.event.inputs.version }} | ||
push: true | ||
targets: | | ||
${{ matrix.rosdistro }}_base_${{ matrix.arch }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,7 +36,7 @@ jobs: | |
uses: levonet/action-restore-branch@master | ||
|
||
- name: Install bloom | ||
run: apt update && apt install -y python3-bloom git | ||
run: apt update && apt install -y python3-bloom git curl | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
@@ -50,7 +50,7 @@ jobs: | |
git config --global user.name "Release Bot" | ||
git config --global user.email "[email protected]" | ||
git config --global --add safe.directory /__w/scenario_simulator_v2/scenario_simulator_v2 | ||
git config --global credential.helper ${{ secrets.GITHUB_TOKEN }} | ||
git config --global credential.helper ${{ secrets.BLOOM_GITHUB_TOKEN }} | ||
git config pull.rebase false | ||
- name: Get old version | ||
|
@@ -142,50 +142,14 @@ jobs: | |
repo: context.repo.repo, | ||
ref: `heads/${context.payload.pull_request.head.ref}`, | ||
}) | ||
push_docker: | ||
needs: release | ||
name: Push Docker Image | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 720 | ||
strategy: | ||
matrix: | ||
rosdistro: [humble] | ||
arch: [amd64] | ||
# Build test for arm64 CPU is broken. | ||
# This is a temporary solution and will be repaired in the future. | ||
# See also https://github.com/tier4/scenario_simulator_v2/pull/1295 | ||
# arch: [amd64, arm64] | ||
steps: | ||
- name: Free Disk Space (Ubuntu) | ||
uses: jlumbroso/free-disk-space@main | ||
with: | ||
tool-cache: false | ||
|
||
- name: Install docker for ubuntu runner | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Install QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
|
||
- uses: actions/checkout@v3 | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build and push (${{ matrix.arch }}) | ||
uses: docker/bake-action@v3 | ||
with: | ||
files: | | ||
./docker-bake.hcl | ||
workdir: . | ||
set: | | ||
*.cache-to=type=gha,mode=max | ||
*.cache-from=type=gha | ||
*.tags=ghcr.io/tier4/scenario_simulator_v2:humble-${{ needs.release.outputs.new_version }} | ||
push: ${{ github.event.pull_request.merged == true }} | ||
targets: | | ||
${{ matrix.rosdistro }}_base_${{ matrix.arch }} | ||
- name: Kick docker build action | ||
if: github.event.pull_request.merged == true | ||
run: | | ||
curl -L \ | ||
-X POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "Authorization: token ${{ secrets.BLOOM_GITHUB_TOKEN }}" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
https://api.github.com/repos/tier4/scenario_simulator_v2/actions/workflows/Docker.yaml/dispatches \ | ||
-d '{"ref":"master","inputs":{"version":"${{ steps.new_version.outputs.new_version }}"}}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.