<commit_before>FROM golang:1.11 as build

# Add the local files to be sure we are building the local source code instead
# of downloading from GitHub. All other package dependencies will be downloaded
# from HEAD.
ADD . /go/src/github.com/m-lab/epoxy
RUN go get -t -v github.com/m-lab/epoxy/...
RUN go test -v github.com/m-lab/epoxy/...
RUN CGO_ENABLED=0 go get -t -v github.com/m-lab/epoxy/cmd/epoxy_boot_server

# Now copy the built binary into a minimal base image.
FROM alpine
COPY --from=build /go/bin/epoxy_boot_server /

# We must install the ca-certificates package so the ePoxy server can securely
# connect to the LetsEncrypt servers to register & create our certificates.
# As well, valid ca-certificates are needed for the storage proxy connections.
RUN apk update && apk add ca-certificates

WORKDIR /
ENTRYPOINT ["/epoxy_boot_server"]<commit_msg>Set CGO_ENABLED before running go test<commit_after>FROM golang:1.11 as build

# Add the local files to be sure we are building the local source code instead
# of downloading from GitHub. All other package dependencies will be downloaded
# from HEAD.
ADD . /go/src/github.com/m-lab/epoxy
ENV CGO_ENABLED 0
RUN go get -t -v github.com/m-lab/epoxy/...
RUN go test -v github.com/m-lab/epoxy/...
RUN go get github.com/m-lab/epoxy/cmd/epoxy_boot_server

# Now copy the built binary into a minimal base image.
FROM alpine
COPY --from=build /go/bin/epoxy_boot_server /

# We must install the ca-certificates package so the ePoxy server can securely
# connect to the LetsEncrypt servers to register & create our certificates.
# As well, valid ca-certificates are needed for the storage proxy connections.
RUN apk update && apk add ca-certificates

WORKDIR /
ENTRYPOINT ["/epoxy_boot_server"]
{'fraction_non_alphanumeric': 0.08204245553643144, 'fraction_numerical': 0.004589787722317842, 'mean_word_length': 3.898876404494382, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '439604', 'n_tokens_mistral': 559, 'n_tokens_neox': 539, 'n_words': 222}