Skip to content

Commit

Permalink
slack-19.0: fix docker base build + git private repo
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
  • Loading branch information
timvaillancourt committed Jul 17, 2024
1 parent 27199c5 commit bfac304
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 0 deletions.
7 changes: 7 additions & 0 deletions docker/base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,16 @@ ARG BUILD_GIT_REV
# Allows docker builds to set the BUILD_TIME
ARG BUILD_TIME

# Allows private repo go dependencies
ARG GH_ACCESS_TOKEN

# Re-copy sources from working tree
COPY --chown=vitess:vitess . /vt/src/vitess.io/vitess

# Allow checkout of github.com/slackhq/vitess-addons (private repo)
ENV GOPRIVATE=github.com/slackhq/vitess-addons
RUN git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/

USER vitess

# Build Vitess
Expand Down
7 changes: 7 additions & 0 deletions docker/base/Dockerfile.mysql57
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,16 @@ ARG BUILD_GIT_REV
# Allows docker builds to set the BUILD_TIME
ARG BUILD_TIME

# Allows private repo go dependencies
ARG GH_ACCESS_TOKEN

# Re-copy sources from working tree
COPY --chown=vitess:vitess . /vt/src/vitess.io/vitess

# Allow checkout of github.com/slackhq/vitess-addons (private repo)
ENV GOPRIVATE=github.com/slackhq/vitess-addons
RUN git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/

USER vitess

# Build Vitess
Expand Down
7 changes: 7 additions & 0 deletions docker/base/Dockerfile.percona57
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,17 @@ ARG BUILD_GIT_REV
# Allows docker builds to set the BUILD_TIME
ARG BUILD_TIME

# Allows private repo go dependencies
ARG GH_ACCESS_TOKEN

# Re-copy sources from working tree
COPY --chown=vitess:vitess . /vt/src/vitess.io/vitess

USER vitess

# Allow checkout of github.com/slackhq/vitess-addons (private repo)
ENV GOPRIVATE=github.com/slackhq/vitess-addons
RUN git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/

# Build Vitess
RUN make build
7 changes: 7 additions & 0 deletions docker/base/Dockerfile.percona80
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,16 @@ ARG BUILD_GIT_REV
# Allows docker builds to set the BUILD_TIME
ARG BUILD_TIME

# Allows private repo go dependencies
ARG GH_ACCESS_TOKEN

# Re-copy sources from working tree
COPY --chown=vitess:vitess . /vt/src/vitess.io/vitess

# Allow checkout of github.com/slackhq/vitess-addons (private repo)
ENV GOPRIVATE=github.com/slackhq/vitess-addons
RUN git config --global url.https://$GH_ACCESS_TOKEN@github.com/.insteadOf https://github.com/

USER vitess

# Build Vitess
Expand Down

0 comments on commit bfac304

Please sign in to comment.