run consul on travis

fixes gh-6
This commit is contained in:
Spencer Gibb
2015-03-31 10:07:13 -06:00
parent 41c8575385
commit e994abeb27
3 changed files with 14 additions and 1 deletions

View File

@@ -5,10 +5,12 @@ before_install:
- git config credential.helper "store --file=.git/credentials"
- echo "https://$GH_TOKEN:@github.com" > .git/credentials
- gem install asciidoctor
- ./src/main/bash/travis_install_consul.sh
install:
- mvn --settings .settings.xml install -P docs -q -U -DskipTests=true -Dmaven.test.redirectTestOutputToFile=true
- ./docs/src/main/asciidoc/ghpages.sh
script:
- ./consul agent -server -bootstrap-expect 1 -data-dir /tmp/consul &
#TODO: change install to deploy
- '[ "${TRAVIS_PULL_REQUEST}" != "false" ] || mvn --settings .settings.xml install -nsu -Dmaven.test.redirectTestOutputToFile=true'
- '[ "${TRAVIS_PULL_REQUEST}" = "false" ] || mvn --settings .settings.xml install -nsu -Dmaven.test.redirectTestOutputToFile=true'

View File

@@ -1,2 +1,2 @@
#!/bin/bash
consul agent -server -bootstrap-expect 1 -data-dir /tmp/consul -ui-dir `dirname $0`/consul_ui
consul agent -server -bootstrap-expect 1 -data-dir /tmp/consul -ui-dir `dirname $0`/../../../consul_ui

View File

@@ -0,0 +1,11 @@
#!/bin/bash
CONSUL_VER="0.5.0_linux_amd64"
# cleanup
rm "${CONSUL_VER}.*"
rm "consul"
# install consul
wget "https://dl.bintray.com/mitchellh/consul/${CONSUL_VER}.zip"
unzip "${CONSUL_VER}.zip"
# check
./consul --version