diff --git a/.github/workflows/check-heartbeat.yml b/.github/workflows/check-heartbeat.yml new file mode 100644 index 00000000000..a0242812a52 --- /dev/null +++ b/.github/workflows/check-heartbeat.yml @@ -0,0 +1,27 @@ +name: check-heartbeat + +on: + pull_request: + paths: + - '.github/workflows/check-heartbeat.yml' + - 'heartbeat/**' + - 'x-pack/heartbeat/**' + +env: + BEAT_MODULE: 'heartbeat' + +jobs: + check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Fetch Go version from .go-version + run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV + - uses: actions/setup-go@v3 + with: + go-version: ${{ env.GO_VERSION }} + - name: Run check/update + run: | + go install github.com/magefile/mage + make -C ${{ env.BEAT_MODULE }} check update + make check-no-changes diff --git a/.github/workflows/check-xpack-heartbeat.yml b/.github/workflows/check-xpack-heartbeat.yml new file mode 100644 index 00000000000..8a3eceb499e --- /dev/null +++ b/.github/workflows/check-xpack-heartbeat.yml @@ -0,0 +1,27 @@ +name: check-x-pack-heartbeat + +on: + pull_request: + paths: + - '.github/workflows/check-xpack-heartbeat.yml' + - 'x-pack/heartbeat/**' + - 'heartbeat/**' + +env: + BEAT_MODULE: 'x-pack/heartbeat' + +jobs: + check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Fetch Go version from .go-version + run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV + - uses: actions/setup-go@v3 + with: + go-version: ${{ env.GO_VERSION }} + - name: Run check/update + run: | + go install github.com/magefile/mage + make -C ${{ env.BEAT_MODULE }} check update + make check-no-changes diff --git a/.github/workflows/opentelemetry.yml b/.github/workflows/opentelemetry.yml index 939cec24b51..ba6b5513cb6 100644 --- a/.github/workflows/opentelemetry.yml +++ b/.github/workflows/opentelemetry.yml @@ -6,12 +6,14 @@ on: - check-auditbeat - check-dev-tools - check-filebeat + - check-heartbeat - check-metricbeat - check-packetbeat - check-winlogbeat - check-x-pack-auditbeat - check-x-pack-filebeat - check-x-pack-functionbeat + - check-x-pack-heartbeat - check-x-pack-metricbeat - check-x-pack-osquerybeat - check-x-pack-packetbeat diff --git a/heartbeat/Jenkinsfile.yml b/heartbeat/Jenkinsfile.yml index 98e024d73b7..87fce6bf9e0 100644 --- a/heartbeat/Jenkinsfile.yml +++ b/heartbeat/Jenkinsfile.yml @@ -13,14 +13,6 @@ when: tags: true ## for all the tags platform: "immutable && ubuntu-18" ## default label for all the stages stages: - checks: - make: | - make -C heartbeat check; - make -C heartbeat update; - make -C x-pack/heartbeat check; - make -C x-pack/heartbeat update; - make check-no-changes; - stage: checks arm: mage: "mage build unitTest" platforms: ## override default label in this specific stage. diff --git a/x-pack/heartbeat/Jenkinsfile.yml b/x-pack/heartbeat/Jenkinsfile.yml index 44cc8cc5c6d..1bd04921e05 100644 --- a/x-pack/heartbeat/Jenkinsfile.yml +++ b/x-pack/heartbeat/Jenkinsfile.yml @@ -13,14 +13,6 @@ when: tags: true ## for all the tags platform: "immutable && ubuntu-18" ## default label for all the stages stages: - checks: - make: | - make -C x-pack/heartbeat check; - make -C x-pack/heartbeat update; - make -C heartbeat check; - make -C heartbeat update; - make check-no-changes; - stage: checks unitTest: mage: "mage build unitTest" withNodejs: true