prometheus-jitsi-meet-exporter/.github/workflows/integration.yaml

86 lines
1.8 KiB
YAML
Raw Normal View History

2020-03-21 20:53:50 +01:00
name: Integration
on:
push:
branches:
- main
2022-10-22 14:35:56 +02:00
pull_request:
2020-03-21 20:53:50 +01:00
jobs:
test:
name: Test
2022-10-22 14:35:56 +02:00
runs-on: ubuntu-20.04
2020-03-21 20:53:50 +01:00
steps:
- uses: actions/checkout@v3
2020-03-21 20:53:50 +01:00
- name: Setup go
uses: actions/setup-go@v4
2020-03-21 20:53:50 +01:00
with:
2022-10-22 14:35:56 +02:00
go-version: "1.17.x"
- name: Cache Go Dependencies
uses: actions/cache@v3
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
2020-03-21 20:53:50 +01:00
- name: Vet
run: go vet
2020-03-21 20:53:50 +01:00
- name: Test
run: go test ./...
2020-03-21 20:53:50 +01:00
build:
name: Build
2022-10-22 14:35:56 +02:00
runs-on: ubuntu-20.04
needs:
- test
2020-03-21 20:53:50 +01:00
steps:
- uses: actions/checkout@v3
2020-03-21 20:53:50 +01:00
- name: Setup go
uses: actions/setup-go@v4
2020-03-21 20:53:50 +01:00
with:
2022-10-22 14:35:56 +02:00
go-version: "1.17.x"
- name: Cache Go Dependencies
uses: actions/cache@v3
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
2020-03-21 20:53:50 +01:00
- name: Build
run: go build ./...
2020-03-21 20:53:50 +01:00
- name: Docker
run: docker build .
2022-10-22 14:35:56 +02:00
automerge:
name: Merge Automatically
needs: [test, build]
runs-on: ubuntu-20.04
permissions:
pull-requests: write
contents: write
steps:
- name: Obtain Access Token
id: acces_token
run: |
TOKEN="$(npx obtain-github-app-installation-access-token ci ${{ secrets.SYSTEMLI_APP_CREDENTIALS_TOKEN }})"
echo "token=$TOKEN" >> $GITHUB_OUTPUT
- name: Merge
uses: fastify/github-action-merge-dependabot@v3
with:
github-token: ${{ steps.acces_token.outputs.token }}