From 1e13174cc2b317d9f9fc310ba880cc3bea27926c Mon Sep 17 00:00:00 2001 From: Graham Date: Sun, 8 Mar 2020 14:07:00 +0000 Subject: [PATCH] Switch from Jenkins to Drone Signed-off-by: Graham --- .drone.yml | 22 ++++++++++++++++++++++ .gitignore | 1 + Jenkinsfile | 30 ------------------------------ README.md | 2 +- 4 files changed, 24 insertions(+), 31 deletions(-) create mode 100644 .drone.yml delete mode 100644 Jenkinsfile diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000000..b6009f85e8 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,22 @@ +kind: pipeline +type: docker +name: default + +steps: + - name: build + image: registry.openrs2.dev/openrs2-dev + commands: + - ./gradlew --no-daemon clean build + + - name: deploy + image: registry.openrs2.dev/openrs2-dev + commands: + - ./gradlew --no-daemon publish + environment: + ORG_GRADLE_PROJECT_openrs2RepoUsername: + from_secret: repo_username + ORG_GRADLE_PROJECT_openrs2RepoPassword: + from_secret: repo_password + when: + branch: + - master diff --git a/.gitignore b/.gitignore index a56a06e656..d599584177 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ .* +!.drone.yml !.editorconfig !.git* !.idea diff --git a/Jenkinsfile b/Jenkinsfile deleted file mode 100644 index cf99903d09..0000000000 --- a/Jenkinsfile +++ /dev/null @@ -1,30 +0,0 @@ -pipeline { - agent any - - stages { - stage('Build') { - steps { - withCredentials([usernamePassword( - credentialsId: 'archiva', - usernameVariable: 'ORG_GRADLE_PROJECT_openrs2RepoUsername', - passwordVariable: 'ORG_GRADLE_PROJECT_openrs2RepoPassword' - )]) { - withGradle { - sh './gradlew --no-daemon clean build publish' - } - } - } - } - } - - post { - always { - junit '**/build/test-results/test/*.xml' - jacoco( - execPattern: '**/build/jacoco/test.exec', - classPattern: '**/build/classes/*/main', - sourcePattern: '**/src/main' - ) - } - } -} diff --git a/README.md b/README.md index 8567c490ce..b3a4cec180 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # OpenRS2 -[![Build status badge](https://build.openrs2.dev/buildStatus/icon?job=openrs2&build=lastCompleted)](https://build.openrs2.dev/job/openrs2/) +[![Build status badge](https://build.openrs2.dev/api/badges/openrs2/openrs2/status.svg)](https://build.openrs2.dev/openrs2/openrs2/) ## Introduction