Skip to content

Commit

Permalink
feat: introduce autoware-nightly.repos (autowarefoundation#5440)
Browse files Browse the repository at this point in the history
* add autoware-nightly.repos

Signed-off-by: Yutaka Kondo <[email protected]>

* add health-check-nightly

Signed-off-by: Yutaka Kondo <[email protected]>

* fix inputs

Signed-off-by: Yutaka Kondo <[email protected]>

* rename

Signed-off-by: Yutaka Kondo <[email protected]>

* change chache condition

Signed-off-by: Yutaka Kondo <[email protected]>

* update .repos

Signed-off-by: Yutaka Kondo <[email protected]>

* vcs import with multiple repos files

Signed-off-by: Yutaka Kondo <[email protected]>

* fix conditions

Signed-off-by: Yutaka Kondo <[email protected]>

* refine

Signed-off-by: Yutaka Kondo <[email protected]>

* style(pre-commit): autofix

* remove comment

Signed-off-by: Yutaka Kondo <[email protected]>

* wip

Signed-off-by: Yutaka Kondo <[email protected]>

* Revert "wip"

This reverts commit 65e89d1.

* wip

Signed-off-by: Yutaka Kondo <[email protected]>

* Update action.yaml

Co-authored-by: M. Fatih Cırıt <[email protected]>

---------

Signed-off-by: Yutaka Kondo <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: M. Fatih Cırıt <[email protected]>
  • Loading branch information
3 people authored Nov 19, 2024
1 parent 39f266a commit abb6b8d
Show file tree
Hide file tree
Showing 3 changed files with 109 additions and 4 deletions.
18 changes: 14 additions & 4 deletions .github/actions/docker-build/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ inputs:
cache-tag-suffix:
description: Suffix of the target cache tag.
required: true
additional-repos:
description: Additional target .repos file.
default: ""
required: false
build-args:
description: Additional build args.
required: false
Expand All @@ -31,9 +35,15 @@ runs:
vcs import src < autoware.repos
shell: bash

- name: Import additional repositories
if: ${{ inputs.additional-repos != '' }}
run: |
vcs import src < ${{ inputs.additional-repos }}
shell: bash

- name: Cache ccache
uses: actions/cache@v4
if: ${{ github.ref == 'refs/heads/main' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.additional-repos == '' }}
id: cache-ccache
with:
path: |
Expand All @@ -44,7 +54,7 @@ runs:
- name: Cache apt-get
uses: actions/cache@v4
if: ${{ github.ref == 'refs/heads/main' }}
if: ${{ github.ref == 'refs/heads/main' && inputs.additional-repos == '' }}
id: cache-apt-get
with:
path: |
Expand All @@ -55,7 +65,7 @@ runs:
- name: Restore ccache
uses: actions/cache/restore@v4
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/main' || inputs.additional-repos != '' }}
with:
path: |
root-ccache
Expand All @@ -65,7 +75,7 @@ runs:
- name: Restore apt-get
uses: actions/cache/restore@v4
if: ${{ github.ref != 'refs/heads/main' }}
if: ${{ github.ref != 'refs/heads/main' || inputs.additional-repos != '' }}
with:
path: |
var-cache-apt
Expand Down
58 changes: 58 additions & 0 deletions .github/workflows/health-check-nightly.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: health-check-nightly

on:
pull_request:
types:
- opened
- synchronize
- reopened
- labeled
schedule:
- cron: 0 6 * * *
workflow_dispatch:

jobs:
label-check:
uses: autowarefoundation/autoware-github-actions/.github/workflows/make-sure-label-is-present.yaml@v1
with:
label: tag:run-health-check

load-env:
needs: label-check
if: ${{ needs.label-check.outputs.result == 'true' ||
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' }}
uses: ./.github/workflows/load-env.yaml

docker-build-nightly:
needs: load-env
runs-on: ubuntu-22.04
strategy:
fail-fast: false
steps:
- name: Check out repository
uses: actions/checkout@v4

- name: Set git config
uses: autowarefoundation/autoware-github-actions/set-git-config@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Free disk space
uses: ./.github/actions/free-disk-space

- name: Build 'Autoware'
uses: ./.github/actions/docker-build
with:
platform: amd64
cache-tag-suffix: nightly
additional-repos: autoware-nightly.repos
build-args: |
ROS_DISTRO=${{ needs.load-env.outputs.rosdistro }}
BASE_IMAGE=${{ needs.load-env.outputs.base_image }}
LIB_DIR=x86_64
- name: Show disk space
if: always()
run: |
df -h
37 changes: 37 additions & 0 deletions autoware-nightly.repos
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
repositories:
core/autoware.core:
type: git
url: https://github.com/autowarefoundation/autoware.core.git
version: main
universe/autoware.universe:
type: git
url: https://github.com/autowarefoundation/autoware.universe.git
version: main
launcher/autoware_launch:
type: git
url: https://github.com/autowarefoundation/autoware_launch.git
version: main
sensor_kit/sample_sensor_kit_launch:
type: git
url: https://github.com/autowarefoundation/sample_sensor_kit_launch.git
version: main
sensor_kit/external/awsim_sensor_kit_launch: # TODO: Integrate into sample_sensor_kit_launch
type: git
url: https://github.com/tier4/awsim_sensor_kit_launch.git
version: main
sensor_kit/awsim_labs_sensor_kit_launch:
type: git
url: https://github.com/autowarefoundation/awsim_labs_sensor_kit_launch.git
version: main
sensor_kit/single_lidar_sensor_kit_launch:
type: git
url: https://github.com/autowarefoundation/single_lidar_sensor_kit_launch.git
version: main
vehicle/sample_vehicle_launch:
type: git
url: https://github.com/autowarefoundation/sample_vehicle_launch.git
version: main
vehicle/awsim_labs_vehicle_launch:
type: git
url: https://github.com/autowarefoundation/awsim_labs_vehicle_launch.git
version: main

0 comments on commit abb6b8d

Please sign in to comment.