generated from actions/hello-world-docker-action
-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (43 loc) · 1.45 KB
/
debug_s3.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Continuous Integration
on:
pull_request:
branches:
- main
push:
branches:
- main
tags:
- "v*.*.*"
permissions:
contents: read
jobs:
debug_s3_bucket:
runs-on: [self-hosted, small]
steps:
- uses: hostwithquantum/setup-mc@main
with:
alias-name: hetzner-bucket
alias-url: https://${{ vars.HETZNER_CACHE_REGION }}.${{ vars.HETZNER_CACHE_ENDPOINT }}
alias-access-key: ${{ secrets.HETZNER_CACHE_ACCESS_KEY }}
alias-secret-key: ${{ secrets.HETZNER_CACHE_SECRET_KEY }}
- name: List bucket
run: mc ls hetzner-bucket/${{ vars.HETZNER_CACHE_BUCKET }}
- uses: actions/checkout@v4
- id: go-cache-paths
run: |
echo "go-build=$(go env GOCACHE)" >> $GITHUB_OUTPUT
echo "go-mod=$(go env GOMODCACHE)" >> $GITHUB_OUTPUT
- name: Go Cache
uses: tespkg/actions-cache@v1
with:
endpoint: ${{ vars.HETZNER_CACHE_REGION }}.${{ vars.HETZNER_CACHE_ENDPOINT }}
bucket: ${{ vars.HETZNER_CACHE_BUCKET }}
accessKey: ${{ secrets.HETZNER_CACHE_ACCESS_KEY }}
secretKey: ${{ secrets.HETZNER_CACHE_SECRET_KEY }}
use-fallback: false
path: |
${{ steps.go-cache-paths.outputs.go-build }}
${{ steps.go-cache-paths.outputs.go-mod }}
key: ${{ runner.os }}-go-test-${{ hashFiles('**/go.sum') }}
- name: Go Build
run: go build -v ./cmd/...