2023-07-21 09:58:08 +00:00
|
|
|
run-name: ${{ github.actor }} is testing
|
|
|
|
on: ["push"]
|
|
|
|
jobs:
|
|
|
|
Release:
|
|
|
|
runs-on: docker
|
|
|
|
#container:
|
|
|
|
# image: goreleaser/goreleaser
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
#- run: goreleaser release --skip-publish --snapshot --rm-dist --debug
|
|
|
|
- name: Setup Go environment
|
|
|
|
uses: https://github.com/actions/setup-go@v2.1.3
|
|
|
|
with:
|
|
|
|
go-version: 1.20
|
|
|
|
- name: Run GoReleaser
|
|
|
|
uses: https://github.com/goreleaser/goreleaser-action@v4
|
|
|
|
with:
|
|
|
|
# either 'goreleaser' (default) or 'goreleaser-pro'
|
|
|
|
distribution: goreleaser
|
|
|
|
version: latest
|
2023-07-21 10:03:25 +00:00
|
|
|
args: release --skip-publish --snapshot --rm-dist --debug --clean
|
2023-07-21 09:58:08 +00:00
|
|
|
env:
|
|
|
|
GORELEASER_FORCE_TOKEN: "gitea"
|
2023-07-21 10:19:16 +00:00
|
|
|
- name: Copy deb to publöish folder
|
|
|
|
run: mkdir publish; cp dist/*deb public/last.deb
|
2023-07-21 10:04:49 +00:00
|
|
|
- name: Upload to s3
|
2023-07-21 10:05:18 +00:00
|
|
|
uses: https://github.com/shallwefootball/s3-upload-action@master
|
2023-07-21 10:04:49 +00:00
|
|
|
with:
|
|
|
|
aws_key_id: ${{ secrets.AWS_KEY_ID }}
|
|
|
|
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY}}
|
|
|
|
aws_bucket: 'kekscloud-releases'
|
2023-07-21 10:19:16 +00:00
|
|
|
source_dir: 'publish/'
|
2023-07-21 10:04:49 +00:00
|
|
|
destination_dir: 'http-server-status/'
|
|
|
|
endpoint: 's3.eu-central-003.backblazeb2.com'
|