Skip to content

Commit

Permalink
Update boilerplate (flyteorg#49)
Browse files Browse the repository at this point in the history
Signed-off-by: Julien Bisconti <veggiemonk@users.noreply.github.com>

Co-authored-by: Haytham Abuelfutuh <haytham@afutuh.com>
  • Loading branch information
veggiemonk and EngHabu committed Jan 26, 2022
1 parent 3a2bfd6 commit 2bbb8f5
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
18 changes: 12 additions & 6 deletions datacalog/Dockerfile
@@ -1,31 +1,37 @@
# WARNING: THIS FILE IS MANAGED IN THE 'BOILERPLATE' REPO AND COPIED TO OTHER REPOSITORIES.
# ONLY EDIT THIS FILE FROM WITHIN THE 'LYFT/BOILERPLATE' REPOSITORY:
# ONLY EDIT THIS FILE FROM WITHIN THE 'FLYTEORG/BOILERPLATE' REPOSITORY:
#
# TO OPT OUT OF UPDATES, SEE https://github.com/lyft/boilerplate/blob/master/Readme.rst
# TO OPT OUT OF UPDATES, SEE https://github.com/flyteorg/boilerplate/blob/master/Readme.rst

FROM golang:1.17.1-alpine3.14 as builder
RUN apk add git openssh-client make curl

# COPY only the go mod files for efficient caching
COPY go.mod go.sum /go/src/github.com/lyft/datacatalog/
WORKDIR /go/src/github.com/lyft/datacatalog
COPY go.mod go.sum /go/src/github.com/flyteorg/datacatalog/
WORKDIR /go/src/github.com/flyteorg/datacatalog

# Pull dependencies
RUN go mod download

# COPY the rest of the source code
COPY . /go/src/github.com/lyft/datacatalog/
COPY . /go/src/github.com/flyteorg/datacatalog/

# This 'linux_compile' target should compile binaries to the /artifacts directory
# The main entrypoint should be compiled to /artifacts/datacatalog
RUN make linux_compile

# install grpc-health-probe
RUN curl --silent --fail --show-error --location --output /artifacts/grpc_health_probe "https://github.com/grpc-ecosystem/grpc-health-probe/releases/download/v0.4.5/grpc_health_probe-linux-amd64" && \
chmod +x /artifacts/grpc_health_probe && \
echo '8699c46352d752d8f533cae72728b0e65663f399fc28fb9cd854b14ad5f85f44 /artifacts/grpc_health_probe' > .grpc_checksum && \
sha256sum -c .grpc_checksum

# update the PATH to include the /artifacts directory
ENV PATH="/artifacts:${PATH}"

# This will eventually move to centurylink/ca-certs:latest for minimum possible image size
FROM alpine:3.14
LABEL org.opencontainers.image.source https://github.com/lyft/datacatalog
LABEL org.opencontainers.image.source https://github.com/flyteorg/datacatalog

COPY --from=builder /artifacts /bin

Expand Down
1 change: 1 addition & 0 deletions datacalog/boilerplate/update.cfg
Expand Up @@ -2,5 +2,6 @@ flyte/docker_build
flyte/golang_test_targets
flyte/golangci_file
flyte/golang_support_tools
flyte/golang_dockerfile
flyte/pull_request_template
flyte/

0 comments on commit 2bbb8f5

Please sign in to comment.