using the go proxy nexus repo if the env vars are set

This commit is contained in:
Erik Brakkee 2024-11-14 21:56:42 +01:00
parent 245dfd80c6
commit e3418f4173
2 changed files with 16 additions and 1 deletions

View File

@ -1,4 +1,9 @@
FROM alpine:3.20.2 as builder FROM wharf.wamblee.org/alpine:3.20.2 as builder
ARG GOPROXY
ARG GOSUMDB
ENV GOPROXY=$GOPROXY
ENV GOSUMDB=$GOSUMDB
RUN apk update && apk add go curl RUN apk update && apk add go curl
RUN mkdir -p /opt/converge/bin RUN mkdir -p /opt/converge/bin

View File

@ -1,4 +1,8 @@
x-proxy-args: &proxy-args
GOPROXY: ${GOPROXY}
GOSUMDB: ${GOSUMDB}
services: services:
converge: converge:
@ -6,8 +10,11 @@ services:
build: build:
context: . context: .
dockerfile: Dockerfile.prod dockerfile: Dockerfile.prod
args:
<<: *proxy-args
ports: ports:
- 8000:8000 - 8000:8000
converge-tester: converge-tester:
@ -15,6 +22,9 @@ services:
build: build:
context: . context: .
dockerfile: Dockerfile.test dockerfile: Dockerfile.test
args:
<<: *proxy-args
profiles: profiles:
- build - build