diff --git a/.github/workflows/check-metricbeat.yml b/.github/workflows/check-metricbeat.yml new file mode 100644 index 000000000000..54f4753531d3 --- /dev/null +++ b/.github/workflows/check-metricbeat.yml @@ -0,0 +1,27 @@ +name: check-metricbeat + +on: + pull_request: + paths: + - '.github/workflows/check-metricbeat.yml' + - 'metricbeat/**' + - 'x-pack/metricbeat/**' + +env: + BEAT_MODULE: 'metricbeat' + +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-metricbeat.yml b/.github/workflows/check-xpack-metricbeat.yml new file mode 100644 index 000000000000..e3bd576c386f --- /dev/null +++ b/.github/workflows/check-xpack-metricbeat.yml @@ -0,0 +1,27 @@ +name: check-x-pack-metricbeat + +on: + pull_request: + paths: + - '.github/workflows/check-xpack-metricbeat.yml' + - 'x-pack/metricbeat/**' + - 'metricbeat/**' + +env: + BEAT_MODULE: 'x-pack/metricbeat' + +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 cd407bef4323..41f5acccd0f0 100644 --- a/.github/workflows/opentelemetry.yml +++ b/.github/workflows/opentelemetry.yml @@ -6,11 +6,13 @@ on: - check-auditbeat - check-dev-tools - check-filebeat + - check-metricbeat - check-packetbeat - check-winlogbeat - check-x-pack-auditbeat - check-x-pack-filebeat - check-x-pack-functionbeat + - check-x-pack-metricbeat - check-x-pack-osquerybeat - check-x-pack-packetbeat - check-x-pack-winlogbeat diff --git a/metricbeat/Jenkinsfile.yml b/metricbeat/Jenkinsfile.yml index 8832fe259fc6..29736ea8c42d 100644 --- a/metricbeat/Jenkinsfile.yml +++ b/metricbeat/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 metricbeat check; - make -C metricbeat update; - make -C x-pack/metricbeat check; - make -C x-pack/metricbeat update; - make check-no-changes; - stage: checks unitTest: mage: "mage build unitTest" stage: mandatory diff --git a/x-pack/metricbeat/Jenkinsfile.yml b/x-pack/metricbeat/Jenkinsfile.yml index fd3e5fb347bd..a61132526c87 100644 --- a/x-pack/metricbeat/Jenkinsfile.yml +++ b/x-pack/metricbeat/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/metricbeat check; - make -C x-pack/metricbeat update; - make -C metricbeat check; - make -C metricbeat update; - make check-no-changes; - stage: checks unitTest: mage: "mage build unitTest" stage: mandatory