make-deploy/simple.mk

21 lines
484 B
Makefile

# simple
#
# this just rsyncs the stuff to the remote server(s) and runs
# build.sh, pre-/post-deploy, pre-/post-local, start.sh, etc.
ifndef DEPLOY_START_DELAY
DEPLOY_START_DELAY = 0
endif
pull-simple:
# nop
start-simple:
@- echo "\n### start"
@- $(foreach host,$(DEPLOY_HOSTS), \
echo "#host: $(host)"; \
set -e; \
if [ -e start.sh ] ; then ssh $(SSH_USER)@$(host) "cd $(DEPLOY_PATH)/$(DEPLOY_NAME); sh start.sh"; fi; \
sleep $(DEPLOY_START_DELAY); \
set +e; \
)