zipkin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From abe...@apache.org
Subject [incubator-zipkin-brave-karaf] 23/37: Migrates to CircleCI 2.0 (#6)
Date Wed, 30 Jan 2019 17:07:11 GMT
This is an automated email from the ASF dual-hosted git repository.

abesto pushed a commit to branch jenkinsfile-wip
in repository https://gitbox.apache.org/repos/asf/incubator-zipkin-brave-karaf.git

commit da4cc9b59703b71aee901b1c500446b3952923df
Author: Zoltán Nagy <abesto0@gmail.com>
AuthorDate: Fri Jul 27 09:52:08 2018 +0200

    Migrates to CircleCI 2.0 (#6)
---
 .circleci/config.yml                  | 139 ++++++++++++++++++++++++++++++++++
 .mvn/wrapper/maven-wrapper.properties |   2 +-
 circle.yml                            |  65 ----------------
 3 files changed, 140 insertions(+), 66 deletions(-)

diff --git a/.circleci/config.yml b/.circleci/config.yml
new file mode 100644
index 0000000..be9d727
--- /dev/null
+++ b/.circleci/config.yml
@@ -0,0 +1,139 @@
+#
+# Copyright 2016-2018 The OpenZipkin Authors
+#
+# Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file
except
+# in compliance with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software distributed under the
License
+# is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
express
+# or implied. See the License for the specific language governing permissions and limitations
under
+# the License.
+#
+
+version: 2
+jobs:
+  build:
+    docker:
+      - image: circleci/openjdk:8-jdk
+
+    steps:
+      - checkout
+
+      - restore_cache:
+          key: maven-dependencies-{{ checksum "pom.xml" }}
+
+      - run:
+          name: Download dependencies
+          command: |
+            sudo apt-get install xsltproc
+            ./build-support/go-offline.sh
+      - save_cache:
+          key: maven-dependencies-{{ checksum "pom.xml" }}
+          paths:
+            - ~/.m2
+
+      - run:
+          name: Tests
+          # use install, as opposed to verify, to ensure invoker tests use latest code
+          command: ./mvnw clean install
+
+      - run:
+          name: Collect test reports
+          command: |
+            mkdir -p /tmp/test-reports/unit-tests/
+            find . -type f -regex ".*/target/surefire-reports/.*xml" -exec cp {} /tmp/test-reports/unit-tests/
\;
+
+      - store_test_results:
+          path: /tmp/test-reports/
+
+  publish_snapshot:
+    docker:
+      - image: circleci/openjdk:8-jdk
+    steps:
+      - checkout
+      - restore_cache:
+          key: maven-dependencies-{{ checksum "pom.xml" }}
+      - run:
+          name: Publish snapshot
+          command: |
+            # Guard against running this on pull requests or forks
+            [ "$CIRCLE_PROJECT_USERNAME" == "openzipkin" ] || exit 0
+            [ -z "$CIRCLE_PR_NUMBER" ] || exit 0
+            ./build-support/publish-snapshot.sh
+
+  publish_stable:
+    docker:
+      - image: circleci/openjdk:8-jdk
+    steps:
+      - checkout
+      - restore_cache:
+          key: maven-dependencies-{{ checksum "pom.xml" }}
+      - run:
+          name: Publish stable version
+          # triples the timeout to 30 minutes as maven central sync takes a lot longer than
10m
+          no_output_timeout: 30m
+          command: |
+            # Guard against running this on pull requests or forks
+            [ "$CIRCLE_PROJECT_USERNAME" == "openzipkin" ] || exit 0
+            [ -z "$CIRCLE_PR_NUMBER" ] || exit 0
+            ./build-support/publish-stable.sh
+
+  trigger_publish:
+    docker:
+      - image: circleci/openjdk:8-jdk
+    steps:
+      - checkout
+      - restore_cache:
+          key: maven-dependencies-{{ checksum "pom.xml" }}
+      - run:
+          name: Configure Git for release
+          command: |
+            # parameters used during release
+            # allocate commits to CI, not the owner of the deploy key
+            git config user.name "zipkinci"
+            git config user.email "zipkinci+zipkin-dev@googlegroups.com"
+            # setup https authentication credentials, used by ./mvnw release:prepare
+            git config credential.helper "store --file=.git/credentials"
+            echo "https://$GH_TOKEN:@github.com" > .git/credentials
+      - run:
+          name: Trigger publish
+          command: |
+            # Guard against running this on pull requests or forks
+            [ "$CIRCLE_PROJECT_USERNAME" == "openzipkin" ] || exit 0
+            [ -z "$CIRCLE_PR_NUMBER" ] || exit 0
+            ./build-support/trigger-publish.sh
+
+
+workflows:
+  version: 2
+  build_and_publish:
+    jobs:
+      - build
+      - publish_snapshot:
+          requires:
+            - build
+          filters:
+            branches:
+              only: master
+      - publish_stable:
+          requires:
+            - build
+          filters:
+            branches:
+              ignore: /.*/
+            tags:
+              only: /\d+\.\d+\.\d+/
+      - trigger_publish:
+          requires:
+            - build
+          filters:
+            branches:
+              ignore: /.*/
+            tags:
+              only: /release-\d+\.\d+\.\d+/
+
+notify:
+  webhooks:
+    - url: https://webhooks.gitter.im/e/22adbb9973299092e6ae
diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties
index 56bb016..c9023ed 100644
--- a/.mvn/wrapper/maven-wrapper.properties
+++ b/.mvn/wrapper/maven-wrapper.properties
@@ -1 +1 @@
-distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.5.0/apache-maven-3.5.0-bin.zip
\ No newline at end of file
+distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.5.4/apache-maven-3.5.4-bin.zip
\ No newline at end of file
diff --git a/circle.yml b/circle.yml
deleted file mode 100644
index cf12423..0000000
--- a/circle.yml
+++ /dev/null
@@ -1,65 +0,0 @@
-#
-# Copyright 2016-2017 The OpenZipkin Authors
-#
-# Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file
except
-# in compliance with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software distributed under the
License
-# is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
express
-# or implied. See the License for the specific language governing permissions and limitations
under
-# the License.
-#
-
-machine:
-  java:
-    version: openjdk8
-  services:
-    - mysql
-  environment:
-    MYSQL_USER: root
-
-dependencies:
-  override:
-    - sudo apt-get install xsltproc
-    - ./build-support/go-offline.sh
-
-test:
-  override:
-    - ./mvnw verify install
-  post:
-    # parameters used during release
-    # allocate commits to CI, not the owner of the deploy key
-    - git config user.name "zipkinci"
-    - git config user.email "zipkinci+zipkin-dev@googlegroups.com"
-    # setup https authentication credentials, used by ./mvnw release:prepare
-    - git config credential.helper "store --file=.git/credentials"
-    - echo "https://$GH_TOKEN:@github.com" > .git/credentials
-    # copy test reports to CircleCI test reports directory
-    - mkdir -p $CIRCLE_TEST_REPORTS/junit/
-    - find . -type f -regex ".*/target/surefire-reports/.*xml" -exec cp {} $CIRCLE_TEST_REPORTS/junit/
\;
-
-# Send notifications to Gitter
-notify:
-  webhooks:
-    - url: https://webhooks.gitter.im/e/22adbb9973299092e6ae
-
-deployment:
-  trigger:
-    owner: openzipkin
-    tag: /release-\d+\.\d+\.\d+/
-    commands:
-      - ./build-support/trigger-publish.sh
-  publish-stable:
-    owner: openzipkin
-    tag: /\d+\.\d+\.\d+/
-    # triples the timeout to 30 minutes as maven central sync takes a lot longer than 10m
-    commands:
-      - ./build-support/publish-stable.sh:
-        timeout: 1800
-  publish-snapshot:
-    owner: openzipkin
-    branch: master
-    commands:
-      - ./build-support/publish-snapshot.sh


Mime
View raw message