X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=Makefile;h=1280862f00c6d4d0f9ff08f1423816f409392167;hb=ddabda845fded2f97bc0e67fa839c36c4ef29d00;hp=c71409bc94e4b323f82405611cd4ed25c4c709a7;hpb=fe5c6d9840aaab12b06cffd20a3c575b67dfbc13;p=myplc.git diff --git a/Makefile b/Makefile index c71409b..1280862 100644 --- a/Makefile +++ b/Makefile @@ -2,14 +2,17 @@ # $Id$ # -BINARIES = plc-config plc-config-tty db-config dns-config refresh-peer.py plc-map.py clean-empty-dirs.py mtail.py renew_reminder.py +BINARIES = plc-config plc-config-tty db-config dns-config plc-map.py clean-empty-dirs.py mtail.py \ + support-scripts/renew_reminder.py support-scripts/gen_aliases.py INIT_SCRIPTS = api bootcd bootmanager crond db dns functions gpg httpd mail network packages postgresql ssh ssl syslog INITS=$(addprefix plc.d/,$(INIT_SCRIPTS)) ########## make sync PLCHOST=hostname ifdef PLCHOST -PLCSSH:=root@$(PLCHOST) +ifdef VSERVER +PLCSSH:=root@$(PLCHOST):/vservers/$(VSERVER) +endif endif LOCAL_RSYNC_EXCLUDES := --exclude '*.pyc' @@ -19,17 +22,16 @@ RSYNC := rsync -a -v $(RSYNC_COND_DRY_RUN) $(RSYNC_EXCLUDES) sync: ifeq (,$(PLCSSH)) - echo "sync: You must define target host as PLCHOST on the command line" - echo " e.g. make sync PLCHOST=private.one-lab.org" ; exit 1 + echo "sync: You must define PLCHOST and VSERVER on the command line" + echo " e.g. make sync PLCHOST=private.one-lab.org VSERVER=myplc01" ; exit 1 else - +$(RSYNC) host.init $(PLCSSH):/etc/init.d/plc - +$(RSYNC) guest.init $(PLCSSH):/plc/root/etc/init.d/plc - +$(RSYNC) $(BINARIES) $(PLCSSH):/plc/root/usr/bin - +$(RSYNC) $(INITS) $(PLCSSH):/plc/root/etc/plc.d - +$(RSYNC) plc_config.py $(PLCSSH):/plc/root/usr/lib/python2.5/site-packages/plc_config.py - +$(RSYNC) default_config.xml $(PLCSSH):/plc/data/etc/planetlab/default_config.xml + +$(RSYNC) guest.init $(PLCSSH)/etc/init.d/plc + +$(RSYNC) $(BINARIES) $(PLCSSH)/usr/bin + +$(RSYNC) $(INITS) $(PLCSSH)/etc/plc.d + +$(RSYNC) plc_config.py $(PLCSSH)/usr/lib/python2.5/site-packages/plc_config.py + +$(RSYNC) default_config.xml $(PLCSSH)/etc/planetlab/default_config.xml @echo XXXXXXXX You might consider running the following command - @echo ssh $(PLCSSH) chroot /plc/root service plc start + @echo ssh $(PLCHOST) service plc start endif