diff --git a/.travis.yml b/.travis.yml index ca6fca0..92e2e06 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,3 +23,14 @@ script: - .travis/backend-lint.sh - .travis/backend-test.sh - .travis/build-package.sh +deploy: + - provider: script + script: .travis/deploy-snapshot.sh + skip_cleanup: true + on: + branch: dev + - provider: script + script: .travis/deploy-release.sh + skip_cleanup: true + on: + tags: true \ No newline at end of file diff --git a/.travis/build-package.sh b/.travis/build-package.sh index 3d8ee90..80c0f45 100755 --- a/.travis/build-package.sh +++ b/.travis/build-package.sh @@ -4,6 +4,7 @@ if test $TRAVIS_TAG then utils/make-package.sh pdnsmanager-$TRAVIS_TAG + utils/make-package.sh pdnsmanager-$TRAVIS_COMMIT else utils/make-package.sh pdnsmanager-$TRAVIS_COMMIT fi diff --git a/.travis/deploy-release.sh b/.travis/deploy-release.sh new file mode 100755 index 0000000..332bcae --- /dev/null +++ b/.travis/deploy-release.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +curl -F "file=@pdnsmanager-$TRAVIS_TAG.tar.gz" -u "travis:$UPLOAD_PASS" 'https://upload.pdnsmanager.org/?action=release' \ No newline at end of file diff --git a/.travis/deploy-snapshot.sh b/.travis/deploy-snapshot.sh new file mode 100755 index 0000000..157fdfb --- /dev/null +++ b/.travis/deploy-snapshot.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +curl -F "file=@pdnsmanager-$TRAVIS_COMMIT.tar.gz" -u "travis:$UPLOAD_PASS" 'https://upload.pdnsmanager.org/?action=snapshot' \ No newline at end of file