diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 0000000..90393c5 --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,40 @@ +version: 2 +jobs: + build: + docker: + - image: springcloud/pipeline-base + user: appuser + environment: + _JAVA_OPTIONS: "-Xms1024m -Xmx2048m" + TERM: dumb + branches: + ignore: + - gh-pages # list of branches to ignore + resource_class: large + steps: + - checkout + - restore_cache: + key: sc-bus-{{ .Branch }} + - run: + name: "Download dependencies" + command: ./mvnw -s .settings.xml -U --fail-never dependency:go-offline || true + - save_cache: + key: sc-bus-{{ .Branch }} + paths: + - ~/.m2 + - run: + name: "Running build" + command: ./mvnw -s .settings.xml clean org.jacoco:jacoco-maven-plugin:prepare-agent install -U -P sonar -nsu --batch-mode -Dmaven.test.redirectTestOutputToFile=true -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn + - run: + name: "Aggregate test results" + when: always + command: | + mkdir -p ~/junit/ + find . -type f -regex ".*/target/.*-reports/.*" -exec cp {} ~/junit/ \; + bash <(curl -s https://codecov.io/bash) + - store_artifacts: + path: ~/junit/ + destination: artifacts + - store_test_results: + path: ~/junit/ + destination: testartifacts \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index be4caac..0000000 --- a/.travis.yml +++ /dev/null @@ -1,32 +0,0 @@ -sudo: false -cache: - directories: - - $HOME/.m2 -language: java -jdk: - - oraclejdk8 -services: - - redis-server -before_install: - - git config user.name "$GIT_NAME" - - git config user.email "$GIT_EMAIL" - - git config credential.helper "store --file=.git/credentials" - - echo "https://$GH_TOKEN:@github.com" > .git/credentials - - gem install asciidoctor -install: -- ./mvnw install -P docs -q -U -DskipTests=true -Dmaven.test.redirectTestOutputToFile=true -- '[ "${MVN_GOAL}" == "deploy" ] && ./docs/src/main/asciidoc/ghpages.sh || echo "Not updating docs"' -script: -- './mvnw -s .settings.xml $MVN_GOAL $MVN_PROFILE -nsu -Dmaven.test.redirectTestOutputToFile=true' -env: - global: - - GIT_NAME="Dave Syer" - - GIT_EMAIL=dsyer@pivotal.io - - CI_DEPLOY_USERNAME=buildmaster - - FEATURE_BRANCH=$(echo ${TRAVIS_BRANCH} | grep -q "^.*/.*$" && echo true || echo false) - - SPRING_CLOUD_BUILD=$(echo ${TRAVIS_REPO_SLUG} | grep -q "^spring-cloud/.*$" && echo true || echo false) - - MVN_GOAL=install - - VERSION=$(mvn validate | grep Building | head -1 | sed -e 's/.* //') - - MILESTONE=$(echo ${VERSION} | egrep 'M|RC' && echo true || echo false) - - MVN_PROFILE=$([ "${MILESTONE}" == "true" ] && echo -P milestone) - - secure: eO6b1PT+fmGvNVVYa9WqMwr7d6RXOx/S0m51KfgpeflqMkMnhnAcC8hzPRA2vmQN1kqRdr3OjN6bazRYsRxlQOYsev4QzDv74E9CTXLXzVi+L98Oq7BqD6MpEAEfZVWz1lvGUiaGKTghS7Tseag3sK5CslPr2LA0UAZWd0v1GUo=