Compare commits

..

9 Commits

Author SHA1 Message Date
0c3797ec30 Merge pull request 'test new build ci image' (#15) from test-new-build into master
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: #15
2022-11-28 02:37:33 +00:00
b78ec08cd1 fix
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is passing
2022-11-28 02:57:32 +01:00
2cb70e2fe7 new image needs diff config
Some checks failed
continuous-integration/drone/pr Build is failing
continuous-integration/drone/push Build is failing
2022-11-28 02:02:40 +01:00
f6d2579b51 trying third image
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone/pr Build is failing
2022-11-28 02:00:45 +01:00
1390c2b97f try diff image
Some checks failed
continuous-integration/drone/pr Build is failing
continuous-integration/drone/push Build is failing
2022-11-28 01:57:37 +01:00
f13b3c80de try custom_dns in config file
Some checks failed
continuous-integration/drone/pr Build is failing
continuous-integration/drone/push Build is failing
2022-11-28 01:49:34 +01:00
39aaf00a6f retry
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone/pr Build is failing
2022-11-28 01:34:05 +01:00
b60ab8b2de test
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone/pr Build is failing
2022-11-28 01:28:51 +01:00
b82a257df3 test new build ci image
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone/pr Build is failing
2022-11-28 01:27:58 +01:00
2 changed files with 18 additions and 14 deletions

View File

@ -1,13 +1,17 @@
kind: pipeline kind: pipeline
name: test-docker-build name: test-docker-build
steps: steps:
- name: test-docker-build - name: test
image: plugins/docker image: docker:dind
settings: volumes:
repo: foo/bar - name: dockersock
dry_run: true path: /var/run/docker.sock
target: final commands:
tags: #- echo nameserver 116.202.204.30 > /etc/resolv.conf
- ${DRONE_COMMIT_SHA} - docker build -t sneak/gohttpserver .
- ${DRONE_BRANCH} volumes:
- name: dockersock
host:
path: /var/run/docker.sock

View File

@ -1,5 +1,5 @@
## lint image ## lint image
FROM golangci/golangci-lint@sha256:9ae3767101cd3468cdaea5b6573dadb358013e05ac38abe37d53646680fd386c AS linter FROM golangci/golangci-lint:v1.50.1
RUN mkdir -p /build RUN mkdir -p /build
WORKDIR /build WORKDIR /build
@ -7,7 +7,7 @@ COPY ./ ./
RUN golangci-lint run RUN golangci-lint run
## build image: ## build image:
FROM golang:1.15-buster AS builder FROM golang:1.19.3-bullseye AS builder
RUN apt update && apt install -y make bzip2 RUN apt update && apt install -y make bzip2
@ -20,14 +20,14 @@ RUN go mod download
COPY ./ ./ COPY ./ ./
#RUN make lint #RUN make lint
RUN make rice-install && make httpd RUN make httpd && mv ./httpd /httpd
RUN go mod vendor RUN go mod vendor
RUN tar -c . | bzip2 > /src.tbz2 RUN tar -c . | bzip2 > /src.tbz2
## output image: ## output image:
FROM debian:buster-slim AS final FROM debian:bullseye-slim AS final
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /build/httpd /app/httpd COPY --from=builder /httpd /app/httpd
COPY --from=builder /src.tbz2 /usr/local/src/src.tbz2 COPY --from=builder /src.tbz2 /usr/local/src/src.tbz2