28 lines
811 B
Docker
28 lines
811 B
Docker
FROM 063932952339.dkr.ecr.us-west-2.amazonaws.com/nim-alpine AS build
|
|
MAINTAINER jonathan@jdbernard.com
|
|
|
|
# TODO: install db_migrate so we can use it below
|
|
# RUN nimble install https://git.jdb-labs.com/jdb/db-migrate.git
|
|
|
|
#RUN apt-get install -y libssl-dev
|
|
COPY personal_measure_api.nimble /pm-api/
|
|
COPY src /pm-api/src
|
|
WORKDIR /pm-api
|
|
RUN nimble build -y
|
|
|
|
FROM alpine
|
|
#RUN apt-get install -y postgresql-client
|
|
RUN apk -v --update add --no-cache \
|
|
ca-certificates \
|
|
libressl2.7-libssl \
|
|
libressl2.7-libcrypto \
|
|
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
|