From 0ae1de0d337a7c6895e2e9b40cff1f290bb60d9e Mon Sep 17 00:00:00 2001 From: James Tombleson Date: Tue, 31 Jan 2023 17:47:04 -0800 Subject: [PATCH] updated the biild to always run swag and sqlc before build: (#39) --- Dockerfile | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Dockerfile b/Dockerfile index 3389e38..0f015e6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,6 +2,15 @@ FROM golang:1.18.4 as build COPY . /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 install github.com/pressly/goose/v3/cmd/goose@latest