2021-04-01 00:55:52 +02:00
|
|
|
name: Test
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [master, develop]
|
|
|
|
pull_request:
|
|
|
|
branches: [master, develop]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout with token
|
|
|
|
if: github.event_name != 'pull_request'
|
2023-03-14 14:41:29 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-04-01 00:55:52 +02:00
|
|
|
with:
|
|
|
|
token: ${{ secrets.API_GITHUB_TOKEN }}
|
|
|
|
|
|
|
|
- name: Checkout without token
|
|
|
|
if: github.event_name == 'pull_request'
|
2023-03-14 14:41:29 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-04-01 00:55:52 +02:00
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
2023-03-14 14:41:29 +01:00
|
|
|
uses: docker/setup-buildx-action@v2
|
2021-04-01 00:55:52 +02:00
|
|
|
|
|
|
|
- name: Docker Build Test
|
|
|
|
run: docker buildx build --load --tag test:test --file ./Dockerfile ./
|
|
|
|
|
|
|
|
- name: Version
|
|
|
|
if: github.event_name != 'pull_request'
|
2023-03-14 14:41:29 +01:00
|
|
|
uses: cycjimmy/semantic-release-action@v3
|
2021-04-01 00:55:52 +02:00
|
|
|
with:
|
|
|
|
semantic_version: 17.4
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.API_GITHUB_TOKEN }}
|