diff --git a/docker-compose.yml b/docker-compose.yml index d861789..76f4aa0 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,6 +5,9 @@ volumes: services: rove-server: + build: + context: . + dockerfile: cmd/rove-server/Dockerfile image: rove-server:latest ports: - "80:80" diff --git a/script/test.sh b/script/test.sh index c27a3ea..e3547eb 100755 --- a/script/test.sh +++ b/script/test.sh @@ -4,11 +4,8 @@ cd "$(dirname "$0")" cd .. set -x -# Build the image -bash script/build.sh - -# Build and start the service -docker-compose up --detach +# Build and start rove-server +docker-compose up --detach --build # Run tests, including integration tests go mod download @@ -17,5 +14,8 @@ go test -v ./... -tags integration -cover -coverprofile=/tmp/c.out # Take down the service docker-compose down +# Check that the cmdline client builds +docker build -f "cmd/rove/Dockerfile" . + # Convert the coverage data to html go tool cover -html=/tmp/c.out -o /tmp/coverage.html \ No newline at end of file