myos/make/apps/def.install.mk

9 lines
441 B
Makefile
Raw Normal View History

2021-06-02 00:54:33 +02:00
# function install-parameters: copy PARAMETERS files to application config folder
2021-02-09 17:05:00 +01:00
define install-parameters
$(eval path:=$(or $(1),$(APP)))
2021-06-02 00:54:33 +02:00
$(eval file:=$(or $(2),$(DOCKER_SERVICE)))
$(eval dest:=$(or $(3),config))
2021-02-09 17:05:00 +01:00
$(eval env:=$(or $(4),$(ENV)))
2021-06-01 01:50:11 +02:00
$(if $(wildcard $(dest)/$(file)),,$(if $(wildcard $(PARAMETERS)/$(env)/$(path)/$(file)),$(ECHO) cp -a $(PARAMETERS)/$(env)/$(path)/$(file) $(dest)))
2021-02-09 17:05:00 +01:00
endef