view Makefile @ 22:34d29998b82f

Handle same remote and local username correctly.
author Omair Majid <omajid@redhat.com>
date Fri, 10 Oct 2014 12:59:32 -0400
parents aea50b6c72d6
children
line wrap: on
line source

#
# This is just a deployment helper.  To use, type "make deploy" or even just "make"
# You will get a permission error if you are not a member of the "icedtea" group
# on the server, or possibly if your account's shell does not permit the use of
# rsync,  It is assumed that your current user has pubkey set up for accessing the
# server.
#
# If your local user is not the same as the remote user, "REMOTE_USER=myuser make"
# will help you out.
#

# Files matching this pattern will *not* be synced in either direction.
EXCLUDE_FILE = rsync-exclude
RSYNC = rsync
REMOTE_SERVER = icedtea.classpath.org
REMOTE_PATH = /var/lib/thermostat-web
REMOTE_ARGS = --exclude-from=$(EXCLUDE_FILE) -arvz ./

ifndef REMOTE_USER
  REMOTE_USER=$(USER)
endif

all:	deploy

deploy:
	$(RSYNC) $(REMOTE_ARGS) $(REMOTE_USER)@$(REMOTE_SERVER):$(REMOTE_PATH)