James Tombleson
65f4281f92
* updated to go 1.18.4 and added alpine dep. Image tested locally * added the first example of how to run the app * added deployment notes * updated bootup logic around the env and how to handle things * swagger update
16 lines
382 B
Docker
16 lines
382 B
Docker
FROM golang:1.18.4 as build
|
|
|
|
COPY . /app
|
|
WORKDIR /app
|
|
RUN go build .
|
|
RUN go install github.com/pressly/goose/v3/cmd/goose@latest
|
|
|
|
FROM alpine:latest as app
|
|
|
|
RUN apk --no-cache add bash libc6-compat
|
|
RUN mkdir /app && mkdir /app/migrations
|
|
COPY --from=build /app/collector /app
|
|
COPY --from=build /go/bin/goose /app
|
|
COPY ./database/migrations/ /app/migrations
|
|
|
|
CMD [ "/app/collector" ] |