Skip to content

Added AMI cleanup tool #4

Added AMI cleanup tool

Added AMI cleanup tool #4

name: AMI cleanup tool CI
on:
pull_request:
branches:
- main
concurrency:
cancel-in-progress: true
group: "Only run one instance of AMI cleanup CI for PR #${{ github.event.number }}"
jobs:
check-if-should-run:
runs-on: ubuntu-latest
permissions:
pull-requests: read
outputs:
should-verify-pr: ${{ steps.filter.outputs.changed }} # True if the AMI cleanup tool changed, false otherwise
steps:
- name: Filter out unrelated changes
uses: dorny/[email protected]
id: filter
with:
filters: |
changed: "tools/ami-cleanup/**"
verify-pr:
runs-on: ubuntu-latest
needs:
- check-if-should-run
if: ${{ needs.check-if-should-run.outputs.should-verify-pr }}
steps:
- name: Checkout repo
uses: actions/[email protected]
- name: Install Earthly
uses: earthly/[email protected]
with:
# renovate: earthly-version
version: v0.7.23
- name: Lint Go code
run: earthly -ci +lint --OUTPUT_FORMAT=github-actions
- name: Run Go tests
run: earthly -ci +test --OUTPUT_FORMAT=github-actions