Skip to content

chore: improved validate #287

chore: improved validate

chore: improved validate #287

Workflow file for this run

name: Build new version
on:
push:
branches: [master]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "^1.21"
- run: make test-integration-docker
name: Run integration tests inside Docker
- run: make test
name: Unit tests
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "^1.21"
- run: make build
name: Build
- run: make build-plugins
name: Build plugins
- uses: actions/upload-artifact@v4
name: Upload build artifacts
with:
name: build-artifacts
path: |
bin/druid
bin/druid_rcon
bin/druid_rcon_web_rust
.docker/entrypoint.sh
.docker/druid-install-command.sh
release:
runs-on: ubuntu-latest
needs: [test, build]
outputs:
version: ${{ steps.version.outputs.version }}
version_tag: ${{ steps.version.outputs.version_tag }}
increment: ${{ steps.version.outputs.increment }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: paulhatch/semantic-version@v5.4.0
id: version
with:
bump_each_commit: true
- run: make build
name: Build
env:
VERSION: ${{ steps.version.outputs.version_tag }}
- run: make build-plugins
name: Build plugins
- name: Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.version.outputs.version_tag }}
prerelease: ${{ steps.version.outputs.increment != 0 }}
make_latest: true
files: |
bin/druid
bin/druid_rcon
bin/druid_rcon_web_rust
.docker/entrypoint.sh
.docker/druid-install-command.sh
docker-builds:
needs: release
uses: ./.github/workflows/docker-builds.yml
with:
version_tag: ${{ needs.release.outputs.version_tag }}
version: ${{ needs.release.outputs.version }}
is_pr: false
secrets:
DOCKERHUB_USERNAME: ${{ vars.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
DRUID_ARTIFACTS_REGISTRY_USERNAME: ${{ vars.DRUID_ARTIFACTS_REGISTRY_USERNAME }}
DRUID_ARTIFACTS_REGISTRY_TOKEN: ${{ secrets.DRUID_ARTIFACTS_REGISTRY_TOKEN }}