Private
Public Access
1
0
Files
data-api/.drone.yml
Ask Bjørn Hansen 1b1413a632
All checks were successful
continuous-integration/drone/push Build is passing
build: Use go 1.26
2026-03-07 16:05:28 -08:00

89 lines
1.6 KiB
YAML

---
kind: pipeline
type: kubernetes
name: default
environment:
GOCACHE: /cache/pkg/cache
GOMODCACHE: /cache/pkg/mod
steps:
- name: fetch-tags
image: alpine/git
commands:
- git fetch --tags
resources:
requests:
cpu: 250
memory: 50MiB
limits:
cpu: 250
memory: 100MiB
- name: test
image: golang:1.26
pull: always
volumes:
- name: go
path: /go
- name: gopkg
path: /cache
commands:
- go test -v ./...
- go build ./...
- name: goreleaser
image: golang:1.26
pull: always
resources:
requests:
cpu: 6000
memory: 1024MiB
limits:
cpu: 10000
memory: 4096MiB
volumes:
- name: go
path: /go
- name: gopkg
path: /cache
environment:
# GITHUB_TOKEN:
# from_secret: GITHUB_TOKEN
commands:
- ./scripts/run-goreleaser
depends_on: [test]
- name: docker
image: harbor.ntppool.org/ntppool/drone-kaniko:main
pull: always
volumes:
- name: go
path: /go
- name: gopkg
path: /cache
settings:
repo: ntppool/data-api
registry: harbor.ntppool.org
auto_tag: true
tags: SHA7,${DRONE_SOURCE_BRANCH}
cache: true
username:
from_secret: harbor_username
password:
from_secret: harbor_password
depends_on: [goreleaser]
volumes:
- name: go
temp: {}
- name: gopkg
claim:
name: go-pkg
---
kind: signature
hmac: f78b7702ee701ed5d31d772e0423fe4583929d623a98520078fb5aa5a536c0ec
...