From a8ec17110571377f038787a783c85d54c07a7d5f Mon Sep 17 00:00:00 2001 From: Aidan Feldman Date: Mon, 16 Jul 2018 11:05:02 -0400 Subject: [PATCH] use Docker Compose for building the API This will help resolve discrepancies between development and production building of the API - in this case, Go dependencies weren't being installed. This should fix the AWS deploy. --- Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 40a19de96..64f7225b2 100644 --- a/Makefile +++ b/Makefile @@ -119,11 +119,10 @@ package-react: @docker cp ./dist/. eapp_react_container:/var/www/html/ @docker commit eapp_react_container eapp_react package-go: - @docker run --rm \ - -v ${PWD}:/go/src/github.com/18F/e-QIP-prototype \ + @docker-compose run --rm \ -w /go/src/github.com/18F/e-QIP-prototype/api/cmd/server \ -e "CGO_ENABLED=0" \ - golang:latest go build -ldflags '-w -extldflags "-static"' + api go build -ldflags '-w -extldflags "-static"' -@mkdir -p ./api/dist/tmp -@mkdir -p ./api/dist/bin -@cp -R ./api/migrations ./api/dist/