From 948a86e4eb39ad7eef3431d71156cc98c2c0c03d Mon Sep 17 00:00:00 2001 From: Madhura Bhave Date: Thu, 12 Oct 2017 16:10:20 -0700 Subject: [PATCH] Build PRs as part of concourse pipeline Closes gh-10526 --- .travis.yml | 14 ------------- ci/pipeline.yml | 53 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+), 14 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index c24efed83f3..00000000000 --- a/.travis.yml +++ /dev/null @@ -1,14 +0,0 @@ -language: java -jdk: - - oraclejdk8 -services: - - mongodb - - redis - - cassandra -sudo: required -cache: - directories: - - $HOME/.m2 -install: true -before_script: travis_wait 45 ./mvnw install -q -U -DskipTests=true -Pfast -Dmaven.test.redirectTestOutputToFile=true -script: ./mvnw install -nsu -Dmaven.test.redirectTestOutputToFile=true -P '!integration' \ No newline at end of file diff --git a/ci/pipeline.yml b/ci/pipeline.yml index e938e0cd272..09af9d133a4 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -8,6 +8,10 @@ resource_types: type: docker-image source: repository: pcfseceng/email-resource +- name: pull-request + type: docker-image + source: + repository: jtarchie/pr resources: - name: git-repo type: git @@ -17,6 +21,13 @@ resources: password: ((github-password)) branch: ((branch)) ignore_paths: ["ci/images/*"] +- name: git-pull-request + type: pull-request + source: + access_token: ((github-access-token)) + repo: ((github-repo-name)) + base: ((branch)) + ignore_paths: ["ci/*"] - name: ci-images-git-repo type: git source: @@ -108,6 +119,46 @@ jobs: properties: "zip.type": "docs" "zip.deployed": "false" +- name: build-pull-requests + serial: true + plan: + - get: spring-boot-ci-image + - get: git-repo + resource: git-pull-request + trigger: true + version: every + - do: + - put: git-pull-request + params: + path: git-repo + status: pending + - task: build-project + timeout: 1h30m + image: spring-boot-ci-image + file: git-repo/ci/tasks/build-project.yml + - aggregate: + - task: build-samples + timeout: 1h30m + image: spring-boot-ci-image + file: git-repo/ci/tasks/build-samples.yml + - task: build-integration-tests + timeout: 1h30m + image: spring-boot-ci-image + file: git-repo/ci/tasks/build-integration-tests.yml + - task: build-deployment-tests + timeout: 1h30m + image: spring-boot-ci-image + file: git-repo/ci/tasks/build-deployment-tests.yml + on_success: + put: git-pull-request + params: + path: git-repo + status: success + on_failure: + put: git-pull-request + params: + path: git-repo + status: failure - name: jdk9-build serial: true plan: @@ -259,3 +310,5 @@ groups: jobs: ["stage-milestone", "stage-rc", "stage-release", "promote-milestone", "promote-rc", "promote-release"] - name: "CI Images" jobs: ["build-spring-boot-ci-images"] +- name: "Build Pull Requests" + jobs: ["build-pull-requests"]