24 lines
620 B
Docker
24 lines
620 B
Docker
FROM 063932952339.dkr.ecr.us-west-2.amazonaws.com/alpine-nim:nim-1.4.8 AS build
|
|
MAINTAINER jonathan@jdbernard.com
|
|
|
|
COPY personal_measure_api.nimble /pm-api/
|
|
COPY src /pm-api/src
|
|
WORKDIR /pm-api
|
|
RUN nimble build -y
|
|
|
|
FROM alpine
|
|
EXPOSE 80
|
|
RUN apk -v --update add --no-cache \
|
|
ca-certificates \
|
|
libcrypto1.1 \
|
|
libssl1.1 \
|
|
pcre \
|
|
postgresql-client
|
|
|
|
COPY --from=build /pm-api/personal_measure_api /
|
|
COPY personal_measure_api.config.prod.json /personal_measure_api.config.json
|
|
CMD ["/personal_measure_api", "serve"]
|
|
|
|
# TODO: replace the above with something like:
|
|
# RUN /db_migrate up && /personal_measure_api serve
|