You've already forked prometheus-fail2ban-exporter
feat: use goreleaser
Some checks failed
Golang Tests / unittest (stable, ubuntu-latest-amd64) (push) Failing after 15s
Golang Tests / unittest (stable, ubuntu-latest-arm64) (push) Failing after 15s
Markdown linter / markdown-lint (push) Failing after 13s
Golang CI lint / golangci (stable, ubuntu-latest-amd64) (push) Failing after 28s
Golang CI lint / golangci (stable, ubuntu-latest-arm64) (push) Failing after 2m39s
Some checks failed
Golang Tests / unittest (stable, ubuntu-latest-amd64) (push) Failing after 15s
Golang Tests / unittest (stable, ubuntu-latest-arm64) (push) Failing after 15s
Markdown linter / markdown-lint (push) Failing after 13s
Golang CI lint / golangci (stable, ubuntu-latest-amd64) (push) Failing after 28s
Golang CI lint / golangci (stable, ubuntu-latest-arm64) (push) Failing after 2m39s
This commit is contained in:
20
.gitea/workflows/markdown-linters.yaml
Normal file
20
.gitea/workflows/markdown-linters.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
name: Markdown linter
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [ "opened", "reopened", "synchronize" ]
|
||||
push:
|
||||
branches: [ '**' ]
|
||||
tags-ignore: [ '**' ]
|
||||
workflow_dispatch: {}
|
||||
|
||||
jobs:
|
||||
markdown-lint:
|
||||
container:
|
||||
image: git.cryptic.systems/volker.raschek/markdownlint:0.45.0
|
||||
runs-on:
|
||||
- ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4.2.2
|
||||
- name: Lint Markdown files
|
||||
run: markdownlint --config .markdownlint.yaml .
|
52
.gitea/workflows/release.yaml
Normal file
52
.gitea/workflows/release.yaml
Normal file
@ -0,0 +1,52 @@
|
||||
name: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags: [ '**' ]
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on:
|
||||
- ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4.2.2
|
||||
- uses: docker/setup-qemu-action@v3.6.0
|
||||
- uses: actions/setup-go@v5.5.0
|
||||
with:
|
||||
go-version: stable
|
||||
- uses: docker/login-action@v3.4.0
|
||||
with:
|
||||
registry: git.cryptic.systems
|
||||
username: ${{ github.repository_owner }}
|
||||
password: ${{ secrets.GIT_CRYPTIC_SYSTEMS_PACKAGE_REGISTRY_TOKEN }}
|
||||
- env:
|
||||
GITEA_TOKEN: ${{ secrets.GIT_CRYPTIC_SYSTEMS_PACKAGE_REGISTRY_TOKEN }}
|
||||
GONOSUMDB: ${{ vars.GONOSUMDB }}
|
||||
GOPROXY: ${{ vars.GOPROXY }}
|
||||
uses: goreleaser/goreleaser-action@v6.3.0
|
||||
with:
|
||||
version: "~> v2"
|
||||
args: release --clean
|
||||
|
||||
sync-to-hub-docker-io:
|
||||
needs:
|
||||
- release
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Copy images to docker.io
|
||||
run: |
|
||||
TAG=$(echo ${{ github.ref_name }} | sed 's/v//gm')
|
||||
|
||||
apt-get update --yes
|
||||
apt-get install --yes skopeo
|
||||
skopeo copy \
|
||||
--all \
|
||||
--dest-password ${{ secrets.DOCKER_IO_PASSWORD }} \
|
||||
--dest-username ${{ secrets.DOCKER_IO_USERNAME }} \
|
||||
--src-password ${{ secrets.GIT_CRYPTIC_SYSTEMS_PACKAGE_REGISTRY_TOKEN }} \
|
||||
--src-username volker.raschek \
|
||||
docker://git.cryptic.systems/volker.raschek/prometheus-fail2ban-exporter:${TAG} \
|
||||
docker://docker.io/volkerraschek/prometheus-fail2ban-exporter:${TAG}
|
@ -1,30 +0,0 @@
|
||||
name: Run unit tests
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- '*'
|
||||
types: [ "opened", "reopened", "synchronize" ]
|
||||
push:
|
||||
branches:
|
||||
- '*'
|
||||
workflow_dispatch: {}
|
||||
|
||||
jobs:
|
||||
test:
|
||||
container:
|
||||
image: docker.io/library/golang:1.24.3
|
||||
runs-on:
|
||||
- ubuntu-latest
|
||||
steps:
|
||||
- name: Install tooling
|
||||
run: |
|
||||
apt-get update --yes
|
||||
apt-get upgrade --yes
|
||||
apt-get install --yes git npm
|
||||
- uses: actions/checkout@v4
|
||||
- env:
|
||||
GOPROXY: ${{ vars.GOPROXY }}
|
||||
GONOSUMDB: ${{ vars.GONOSUMDB }}
|
||||
name: Execute containerized unit test
|
||||
run: make test
|
20
.gitea/workflows/update-docker-hub-description.yaml
Normal file
20
.gitea/workflows/update-docker-hub-description.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
name: Update Docker Hub Description
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ 'master' ]
|
||||
paths: [ 'README.md' ]
|
||||
workflow_dispatch: {}
|
||||
|
||||
jobs:
|
||||
update-description-on-hub-docker-io:
|
||||
runs-on:
|
||||
- ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4.2.2
|
||||
- uses: peter-evans/dockerhub-description@v4.0.2
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_IO_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_IO_PASSWORD }}
|
||||
repository: volkerraschek/prometheus-fail2ban-exporter
|
||||
readme-filepath: README.md
|
Reference in New Issue
Block a user