Skip to content

Commit

Permalink
updates
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuarli committed Sep 27, 2021
1 parent 640036d commit d082515
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 10 deletions.
18 changes: 8 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
FROM golang:1.13-alpine3.11 AS builder
FROM golang:1.17-alpine3.14 AS builder

RUN mkdir -p /src/src
WORKDIR /usr/src
ARG GOOGLE_CLOUD_GO_VERSION
ENV GOOGLE_CLOUD_GO_VERSION $GOOGLE_CLOUD_GO_VERSION

ENV GOOGLE_CLOUD_GO_VERSION v0.51.0
RUN busybox wget "https://github.com/googleapis/google-cloud-go/archive/${GOOGLE_CLOUD_GO_VERSION}.tar.gz" -O- | \
busybox tar x --strip-components 1 -zf - && \
cd bigtable && \
go install -v ./cmd/emulator

RUN apk add --no-cache git

RUN git clone --depth=1 --branch="$GOOGLE_CLOUD_GO_VERSION" https://github.com/googleapis/google-cloud-go.git . \
&& cd bigtable \
&& go install -v ./cmd/emulator

FROM alpine:3.11
FROM alpine:3.14

COPY --from=builder /go/bin/emulator /bin/cbtemulator

Expand Down
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
VERSION := 23c02d92c7a1747068eb1fc57dddbad23907d614

build:
docker build -t us.gcr.io/sentryio/cbtemulator:$(VERSION) --build-arg=GOOGLE_CLOUD_GO_VERSION=$(VERSION) .

# Ideally craft's set up to release to here, but some ops people
# have permissions to push to the sentryio project, and
# cbtemulator doesn't really need updates often.
publish: build
docker push us.gcr.io/sentryio/cbtemulator:$(VERSION)

0 comments on commit d082515

Please sign in to comment.