drone-test/.drone.yml

61 lines
1.1 KiB
YAML
Raw Normal View History

2021-10-30 23:32:11 -07:00
---
2020-05-24 21:45:54 -07:00
kind: pipeline
type: kubernetes
name: default
steps:
2021-10-31 00:36:40 -07:00
- name: test
2024-11-27 19:16:27 -08:00
image: golang:1.23.3
2021-10-31 00:36:40 -07:00
commands:
2023-06-03 17:33:22 -07:00
- pwd
2021-10-31 00:36:40 -07:00
- go test -v
- go build
- echo "hello" > /shared/greetings.txt
- hostname >> /shared/greetings.txt
volumes:
- name: shared
path: /shared
resources:
limits:
cpu: 1000
memory: 300MiB
requests:
cpu: 500
memory: 200MiB
2021-10-31 00:33:52 -07:00
2021-10-31 00:36:40 -07:00
- name: read
pull: if-not-exists
image: alpine
volumes:
- name: shared
path: /shared
commands:
- pwd
- ls /shared
- cat /shared/greetings.txt
- name: docker
2023-06-03 17:33:22 -07:00
image: harbor.ntppool.org/ntppool/drone-kaniko:main
2021-10-31 00:36:40 -07:00
pull: always
settings:
2021-11-08 10:25:01 -08:00
repo: ask/drone-test
2021-10-31 00:36:40 -07:00
registry: harbor.ntppool.org
auto_tag: true
tags: SHA7,${DRONE_SOURCE_BRANCH}
cache: true
username:
from_secret: harbor_username
password:
from_secret: harbor_password
2021-10-30 23:30:34 -07:00
volumes:
2021-10-31 00:36:40 -07:00
- name: shared
claim:
name: go-pkg
2021-10-30 23:32:11 -07:00
---
kind: signature
2024-11-27 19:16:27 -08:00
hmac: d251c6c49b413a1db16481ea7f75050ab2775ab9ec9e52c8770f06232cf28058
2021-10-30 23:32:11 -07:00
...