Archived
2
0
This repository has been archived on 2023-03-02. You can view files and clone it, but cannot push or open issues or pull requests.
kerma/Makefile

60 lines
1000 B
Makefile
Raw Permalink Normal View History

2023-03-02 14:28:43 +00:00
WORKDIR=$(shell pwd)
.PHONY: all
all: build
.PHONY: build
build:
cd $(WORKDIR) && go build -o out/kermago
.PHONY: test
test:
cd $(WORKDIR) && go test -v -coverpkg=./... ./...
.PHONY: format
format:
cd $(WORKDIR) && gofmt -l -s -w .
.PHONY: clean
clean:
rm -rf /var/local/badkerma/*.json
.PHONY: run
run:
cd $(WORKDIR) && go run .
.PHONY: clean-run
clean-run: clean run
.PHONY: debug
debug:
cd $(WORKDIR) && KERMA_DEBUG=true go run .
.PHONY: clean-debug
clean-debug: clean debug
.PHONY: docker-build
docker-build:
docker-compose build
.PHONY: docker-push
docker-push: docker-build
docker-compose push
.PHONY: docker-debug
docker-debug: docker-build
KERMA_DEBUG=true docker-compose up
.PHONY: docker-run
docker-run: docker-build
docker-compose up -d
.PHONY: docker-stop
docker-stop:
docker-compose down
.PHONY: lint
lint:
docker pull docker.io/oxsecurity/megalinter:latest
docker run -e DEFAULT_WORKSPACE='/src' -v "$(shell pwd):/src" docker.io/oxsecurity/megalinter:latest