mirror of
https://github.com/amir20/dozzle.git
synced 2025-12-21 13:23:07 +01:00
Uses Go1.16 embed feature (#1092)
* Uses Go1.16 embed feature * Fixes tests * Removes packr and fixes tests
This commit is contained in:
21
Makefile
21
Makefile
@@ -1,6 +1,27 @@
|
||||
TAG := $(shell git describe --tags)
|
||||
PLATFROMS := linux/amd64,linux/arm/v7,linux/arm64/v8
|
||||
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
docker buildx build --build-arg TAG=$(TAG) --platform $(PLATFROMS) -t amir20/dozzle:latest -t amir20/dozzle:$(TAG) --push .
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
@rm -rf static dozzle
|
||||
|
||||
static: $(shell find assets -type f)
|
||||
ifdef SKIP_ASSET
|
||||
@echo 'Skipping yarn build'
|
||||
@mkdir -p static
|
||||
@touch static/index.html
|
||||
else
|
||||
yarn build
|
||||
endif
|
||||
|
||||
.PHONY: test
|
||||
test: static
|
||||
go test -cover ./...
|
||||
|
||||
build: static
|
||||
CGO_ENABLED=0 go build -ldflags "-s -w"
|
||||
|
||||
Reference in New Issue
Block a user