Skip to content

Commit

Permalink
travis deploy script
Browse files Browse the repository at this point in the history
  • Loading branch information
nabeelio committed Dec 13, 2017
1 parent b99872e commit eb11d62
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
12 changes: 1 addition & 11 deletions .travis.yml
Expand Up @@ -39,14 +39,4 @@ deploy:
skip_cleanup: true
on:
branch: master
script: - |
if test "$TRAVIS_TAG"
then
PKG_NAME=$TRAVIS_TAG.tar.gz
else
PKG_NAME=nightly.tar.gz
fi

rm -rf .git deploy_rsa.enc .idea phpvms.iml
tar -czvf $PKG_NAME.tar.gz -C $TRAVIS_BUILD_DIR .
rsync -r --delete-after --quiet $PKG_NAME.tar.gz downloads@phpvms.net:/var/www/downloads/
script: make deploy-package
12 changes: 12 additions & 0 deletions Makefile
Expand Up @@ -63,6 +63,18 @@ schema:
#php artisan infyom:scaffold Aircraft --fieldsFile=database/schema/aircraft.json
echo ""

.PHONY: deploy-package
deploy-package:
ifeq ($(TRAVIS_TAG),)
PKG_NAME=$TRAVIS_TAG
else
PKG_NAME=nightly
fi

rm -rf .git deploy_rsa.enc .idea phpvms.iml
tar -czvf $PKG_NAME.tar.gz -C $TRAVIS_BUILD_DIR .
rsync -r --delete-after --quiet $PKG_NAME.tar.gz downloads@phpvms.net:/var/www/downloads/

.PHONY: docker
docker:
@mkdir -p $(CURR_PATH)/tmp/mysql
Expand Down

0 comments on commit eb11d62

Please sign in to comment.