Compare commits

..

15 Commits
master ... main

Author SHA1 Message Date
2df1862cdd Upgrade to go 1.23
All checks were successful
continuous-integration/drone/push Build is passing
2024-11-27 19:16:27 -08:00
c0c61a71c2 go 1.21.3
All checks were successful
continuous-integration/drone/push Build is passing
2023-10-22 17:08:40 -07:00
3489bd14fc Test that docker can be USER root
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-12 11:16:45 -07:00
cb09f8818d Update Go and Alpine
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-03 17:44:32 -07:00
57958bd383 Update golang and drone-kaniko
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone Build is passing
2021-11-08 13:31:27 -08:00
3abd4c1519 debug kaniko image
Some checks failed
continuous-integration/drone/push Build is failing
2021-11-08 11:47:17 -08:00
67ac0b03a5 Use specific kaniko image
Some checks failed
continuous-integration/drone/push Build is failing
2021-11-08 11:38:03 -08:00
c3824dc377 Fix .drone.yml signature 2021-11-08 11:28:28 -08:00
a6d44cf54a Stop using drone-builds namespace
Some checks failed
continuous-integration/drone/push Build is failing
2021-11-08 10:25:01 -08:00
b7f30d3436 volume test
Some checks failed
continuous-integration/drone/push Build is failing
2021-10-31 00:41:27 -07:00
ccd503b0e7 Try sample from github
All checks were successful
continuous-integration/drone/push Build is passing
2021-10-31 00:33:52 -07:00
4dd5054000 set privileged to get volume mount
Some checks reported errors
continuous-integration/drone/push Build encountered an error
2021-10-31 00:30:25 -07:00
989a491429 More volume testing
Some checks failed
continuous-integration/drone/push Build is failing
2021-10-31 00:08:30 -07:00
1b8d1d0725 Sign drone file
All checks were successful
continuous-integration/drone/push Build is passing
2021-10-30 23:32:11 -07:00
1d9e4c71d3 Test volume mount
Some checks reported errors
continuous-integration/drone/push Build encountered an error
2021-10-30 23:30:34 -07:00
3 changed files with 60 additions and 28 deletions

View File

@ -1,31 +1,60 @@
---
kind: pipeline
type: kubernetes
name: default
steps:
- name: test
image: golang:1.16.3
commands:
- go test -v
- go build
resources:
limits:
cpu: 1000
memory: 300MiB
requests:
cpu: 500
memory: 200MiB
- name: test
image: golang:1.23.3
commands:
- pwd
- 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
- name: docker
image: harbor.ntppool.org/ntppool/drone-kaniko:latest
pull: always
settings:
repo: drone-builds/drone-test
registry: harbor.ntppool.org
auto_tag: true
tags: SHA7,${DRONE_SOURCE_BRANCH}
cache: true
username:
from_secret: harbor_username
password:
from_secret: harbor_password
- name: read
pull: if-not-exists
image: alpine
volumes:
- name: shared
path: /shared
commands:
- pwd
- ls /shared
- cat /shared/greetings.txt
- name: docker
image: harbor.ntppool.org/ntppool/drone-kaniko:main
pull: always
settings:
repo: ask/drone-test
registry: harbor.ntppool.org
auto_tag: true
tags: SHA7,${DRONE_SOURCE_BRANCH}
cache: true
username:
from_secret: harbor_username
password:
from_secret: harbor_password
volumes:
- name: shared
claim:
name: go-pkg
---
kind: signature
hmac: d251c6c49b413a1db16481ea7f75050ab2775ab9ec9e52c8770f06232cf28058
...

View File

@ -1,8 +1,11 @@
FROM golang:1.16.4-alpine3.13 as builder
FROM golang:1.23.3-alpine3.20 as builder
WORKDIR /go/src/gitea.develooper.com/ask/drone-test
ADD . .
RUN CGO_ENABLED=1 GOOS=linux go build -o demo
FROM alpine:3.13 as production
FROM alpine:3.20 as production
USER root
COPY --from=builder /go/src/gitea.develooper.com/ask/drone-test/demo .
CMD ["./demo"]

2
go.mod
View File

@ -1,3 +1,3 @@
module gitea.develooper.com/ask/drone-test
go 1.16
go 1.23