X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=Makefile;h=45add834e49e31b13e09f9deb4e91cd624faec5e;hb=4ef76bd85ea24906c4ebb580c896fe1084d6ba88;hp=40394d272a4c6805e3afcdd4bf9130b6ffa50e30;hpb=0a4c02a2bf0bf21726a6decf3e7f3f01ed32d89a;p=sfa.git diff --git a/Makefile b/Makefile index 40394d27..45add834 100644 --- a/Makefile +++ b/Makefile @@ -22,10 +22,6 @@ rpmtaglevel:=$(shell rpm -q --specfile sfa.spec --queryformat="%{release}\n" 2> VERSIONTAG=$(rpmversion)-$(rpmtaglevel) # this used to be 'should-be-redefined-by-specfile' and it indeed should be SCMURL=git://git.onelab.eu/sfa.git -TARBALL_HOST=root@build.onelab.eu -TARBALL_TOPDIR=/build/sfa -# I have an alternate pypitest entry defined in my .pypirc -PYPI_TARGET=pypi python: version @@ -142,6 +138,11 @@ signatures: .PHONY: signatures ########## for uploading onto pypi +# use pypitest instead for tests (both entries need to be defined in your .pypirc) +PYPI_TARGET=pypi +PYPI_TARBALL_HOST=root@build.onelab.eu +PYPI_TARBALL_TOPDIR=/build/sfa + # a quick attempt on pypitest did not quite work as expected # I was hoping to register the project using "setup.py register" # but somehow most of my meta data did not make it up there @@ -152,21 +153,23 @@ signatures: # did not seem to work the way I was trying to use it, so ... # this target is still helpful to produce the readme in html from README.md -index.zip: README.md +index.zip index.html: README.md python readme.py # I need to run this on my mac as my pypi # run git pull first as this often comes afet a module-tag # we need to re-run make so the version is right -git_pypi: +git_pypi: git pypi + +git: git pull - $(MAKE) pypi + $(MAKE) version # run this only once the sources are in on the right tag -pypi: +pypi: index.html setup.py sdist upload -r $(PYPI_TARGET) - ssh $(TARBALL_HOST) mkdir -p $(TARBALL_TOPDIR)/$(VERSIONTAG) - rsync -av dist/sfa-$(VERSIONTAG).tar.gz $(TARBALL_HOST):$(TARBALL_TOPDIR)/$(VERSIONTAG) + ssh $(PYPI_TARBALL_HOST) mkdir -p $(PYPI_TARBALL_TOPDIR)/$(VERSIONTAG) + rsync -av dist/sfa-$(VERSIONTAG).tar.gz $(PYPI_TARBALL_HOST):$(PYPI_TARBALL_TOPDIR)/$(VERSIONTAG) # cleanup clean: readme-clean @@ -188,7 +191,7 @@ SSHCOMMAND:=ssh root@$(PLC) else ifdef PLCHOSTLXC SSHURL:=root@$(PLCHOSTLXC):/vservers/$(GUESTNAME) -SSHCOMMAND:=ssh root@$(PLCHOSTLXC) virsh -c lxc:/// lxc-enter-namespace $(GUESTNAME) -- /usr/bin/env +SSHCOMMAND:=ssh root@$(PLCHOSTLXC) ssh -o StrictHostKeyChecking=no $(GUESTHOSTNAME) else ifdef PLCHOSTVS SSHURL:=root@$(PLCHOSTVS):/vservers/$(GUESTNAME) @@ -223,6 +226,8 @@ synclib: synccheck +$(RSYNC) --relative ./sfa/ --exclude migrations $(SSHURL)/usr/lib\*/python2.\*/site-packages/ synclibdeb: synccheck +$(RSYNC) --relative ./sfa/ --exclude migrations $(SSHURL)/usr/share/pyshared/ +syncmigrations: + +$(RSYNC) ./sfa/storage/migrations/versions/*.py $(SSHURL)/usr/share/sfa/migrations/versions/ syncbin: synccheck +$(RSYNC) $(BINS) $(SSHURL)/usr/bin/ syncinit: synccheck