summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authormo khan <mo@mokhan.ca>2025-05-15 09:11:16 -0600
committermo khan <mo@mokhan.ca>2025-05-15 09:11:16 -0600
commit3d01a69471fc4f0ae9f2f4145620b6aea50f2216 (patch)
treef85607ebfb2575bce94b5618250ebd957f965f6e /Makefile
parent7c75fac3360b8bc3df630b5f8e12b2ff927a2d23 (diff)
parent564e140de454c78d7e6d34044bb78f53bd0b2bf3 (diff)
Merge branch 'envoy-start' into 'main'
Enable Envoy to run consistently locally and in Docker See merge request gitlab-org/software-supply-chain-security/authorization/sparkled!6
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 8 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index c3b2307..643db68 100644
--- a/Makefile
+++ b/Makefile
@@ -4,11 +4,11 @@ IMAGE_TAG := $(PROJECT_NAME):$(GIT_BRANCH)
.PHONY: clean setup build test run
-sparkled:
- @go build -o sparkled ./cmd/sparkled/main.go
+bin/sparkled:
+ @go build -o ./bin/sparkled ./cmd/sparkled/main.go
clean:
- @rm -f sparkled
+ @rm -f ./bin/sparkled
@go clean -testcache
@docker image rm -f $(IMAGE_TAG)
@@ -16,26 +16,27 @@ setup:
@mise install
@go install tool
@command -v godotenv
+ @command -v playwright
@command -v yamlfmt
-build: sparkled
+build: bin/sparkled
test-unit:
@go test -shuffle=on ./...
test-integration: build-image
- @IMAGE_TAG=$(IMAGE_TAG) go test -tags=integration ./test/integration/...
+ @IMAGE_TAG=$(IMAGE_TAG) go test -v -tags=integration ./test/integration/...
test: clean test-unit test-integration
build-image:
- @docker build --tag $(IMAGE_TAG) .
+ @docker build --no-cache --tag $(IMAGE_TAG) .
build-builder-image:
@docker build --target build --tag $(IMAGE_TAG) .
run: clean build
- @godotenv -f .env.local,.env ./sparkled
+ @godotenv -f .env.local,.env ./bin/init.sh
run-image: clean build-image
@docker run --rm --network host --env-file .env.local -p 10000:10000 -p 9901:9901 -p 8080:8080 -it $(IMAGE_TAG)