diff --git a/.woodpecker/deploy.yml b/.woodpecker/deploy.yml index 36f5034..fbd7856 100644 --- a/.woodpecker/deploy.yml +++ b/.woodpecker/deploy.yml @@ -6,9 +6,13 @@ steps: repo: git.faercol.me/polyculeconnect/polyculeconnect tags: latest dry_run: true + build_args_from_env: + - GOPROXY platforms: - linux/amd64 # - linux/arm64 + environment: + - GOPROXY=http://goproxy.home:3000 when: - event: pull_request - event: push @@ -22,6 +26,8 @@ steps: repo: git.faercol.me/polyculeconnect/polyculeconnect registry: git.faercol.me tags: latest + build_args_from_env: + - GOPROXY username: from_secret: git_username password: @@ -29,6 +35,8 @@ steps: platforms: - linux/amd64 # - linux/arm64 + environment: + - GOPROXY=http://goproxy.home:3000 when: - event: push branch: main @@ -40,6 +48,8 @@ steps: registry: git.faercol.me repo: git.faercol.me/polyculeconnect/polyculeconnect auto_tag: true + build_args_from_env: + - GOPROXY platforms: - linux/amd64 # - linux/arm64 @@ -47,6 +57,8 @@ steps: from_secret: git_username password: from_secret: git_password + environment: + - GOPROXY=http://goproxy.home:3000 when: - event: tag diff --git a/.woodpecker/test.yml b/.woodpecker/test.yml index be910ab..b4674c8 100644 --- a/.woodpecker/test.yml +++ b/.woodpecker/test.yml @@ -3,11 +3,15 @@ steps: image: golang commands: - make -C polyculeconnect test + environment: + - GOPROXY=http://goproxy.home:3000 go-build: image: golang commands: - make -C polyculeconnect build + environment: + - GOPROXY=http://goproxy.home:3000 when: event: [push, tag] diff --git a/Dockerfile b/Dockerfile index cb9aa2a..b1b69d5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,7 @@ FROM --platform=$TARGETPLATFORM golang:1.20 AS builder ARG TARGETPLATFORM ARG BUILDPLATFORM +ARG GOPROXY WORKDIR /go/src/git.faercol.me/polyculeconnect COPY polyculeconnect ./ RUN make build