updated the biild to always run swag and sqlc before build: (#39)

This commit is contained in:
James Tombleson 2023-01-31 17:47:04 -08:00 committed by GitHub
parent 8704680e82
commit 0ae1de0d33
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,6 +2,15 @@ FROM golang:1.18.4 as build
COPY . /app COPY . /app
WORKDIR /app WORKDIR /app
# Always make sure that swagger docs are updated
RUN go install github.com/swaggo/swag/cmd/swag@latest
RUN /go/bin/swag i
# Always build the latest sql queries
RUN go install github.com/kyleconroy/sqlc/cmd/sqlc@latest
RUN /go/bin/sqlc generate
RUN go build . RUN go build .
RUN go install github.com/pressly/goose/v3/cmd/goose@latest RUN go install github.com/pressly/goose/v3/cmd/goose@latest