feat: add a Makefile
commit c0a2c5d5d1af60d1493eb29fec6a89363512040a Author: surtur <a_mirre@utb.cz> Date: Wed Dec 2 02:25:22 2020 +0100 feat: add a Makefile for easy profit [skip ci]
This commit is contained in:
parent
68c5d6b57f
commit
709b15c17f
25
Makefile
Normal file
25
Makefile
Normal file
@ -0,0 +1,25 @@
|
||||
dcmd = docker
|
||||
dfile = Dockerfile
|
||||
dtag = immawanderer/fedora-hugo:testbuild
|
||||
dargs = build -t $(dtag) --pull - < $(dfile)
|
||||
cleanargs = image rm -f $(dtag)
|
||||
pruneargs = system prune af.
|
||||
dargskaniko = run --rm -it -w=$(kanikowdir) -v $$PWD:$(kanikowdir)
|
||||
kanikoexecutorimg = gcr.io/kaniko-project/executor
|
||||
kanikowdir = /src
|
||||
kanikocontext = .
|
||||
kanikoargs = -f=$(dfile) -c=$(kanikocontext) --use-new-run --snapshotMode=redo --no-push
|
||||
|
||||
.PHONY: build kaniko clean prune
|
||||
|
||||
kaniko:
|
||||
$(dcmd) $(dargskaniko) $(kanikoexecutorimg) $(kanikoargs)
|
||||
|
||||
build:
|
||||
$(dcmd) $(dargs)
|
||||
|
||||
clean:
|
||||
$(dcmd) $(cleanargs)
|
||||
|
||||
prune:
|
||||
$(dcmd) $(pruneargs)
|
Loading…
Reference in New Issue
Block a user