Merge pull request #932 from corda/clint-releasefixes

Misc fixes for the release process
This commit is contained in:
Clinton 2017-07-04 19:33:33 +01:00 committed by GitHub
commit 1707fb67c1
17 changed files with 34 additions and 79 deletions

View File

@ -1,4 +1,3 @@
buildscript {
// For sharing constants between builds
Properties constants = new Properties()
@ -75,6 +74,7 @@ plugins {
// but the DSL has some restrictions e.g can't be used on the allprojects section. So we should revisit this if there are improvements in Gradle.
// Version 1.0.2 of this plugin uses capsule:1.0.1
id "us.kirchmeier.capsule" version "1.0.2"
id "com.jfrog.artifactory" version "4.4.18"
}
ext {
@ -85,6 +85,7 @@ apply plugin: 'project-report'
apply plugin: 'com.github.ben-manes.versions'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'net.corda.plugins.cordformation'
apply plugin: 'maven-publish'
// We need the following three lines even though they're inside an allprojects {} block below because otherwise
// IntelliJ gets confused when importing the project and ends up erasing and recreating the .idea directory, along
@ -248,7 +249,7 @@ bintrayConfig {
projectUrl = 'https://github.com/corda/corda'
gpgSign = true
gpgPassphrase = System.getenv('CORDA_BINTRAY_GPG_PASSPHRASE')
publications = ['corda-jfx', 'corda-mock', 'corda-rpc', 'corda-core', 'corda', 'cordform-common', 'corda-finance', 'corda-node', 'corda-node-api', 'corda-node-schemas', 'corda-test-common', 'corda-test-utils', 'corda-jackson', 'corda-verifier', 'corda-webserver-impl', 'corda-webserver']
publications = ['corda-jfx', 'corda-mock', 'corda-rpc', 'corda-core', 'corda', 'corda-finance', 'corda-node', 'corda-node-api', 'corda-node-schemas', 'corda-test-common', 'corda-test-utils', 'corda-jackson', 'corda-verifier', 'corda-webserver-impl', 'corda-webserver']
license {
name = 'Apache-2.0'
url = 'https://www.apache.org/licenses/LICENSE-2.0'
@ -273,3 +274,17 @@ task buildCordappDependenciesZip(type: Zip) {
from 'node/capsule/NOTICE' // CDDL notice
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
}
artifactory {
publish {
contextUrl = 'https://ci-artifactory.corda.r3cev.com/artifactory'
repository {
repoKey = 'corda-releases'
username = 'teamcity'
password = System.getenv('CORDA_ARTIFACTORY_PASSWORD')
}
defaults {
publications('corda-jfx', 'corda-mock', 'corda-rpc', 'corda-core', 'corda', 'cordform-common', 'corda-finance', 'corda-node', 'corda-node-api', 'corda-node-schemas', 'corda-test-utils', 'corda-jackson', 'corda-verifier', 'corda-webserver-impl', 'corda-webserver')
}
}
}

View File

@ -1,6 +1,7 @@
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
dependencies {
compile project(':core')

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda client JavaFX modules'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda client mock modules'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda client RPC modules'

View File

@ -6,6 +6,10 @@ repositories {
mavenCentral()
}
// This tracks the gradle plugins version and not Corda
version gradle_plugins_version
group 'net.corda.plugins'
dependencies {
// TypeSafe Config: for simple and human friendly config files.
compile "com.typesafe:config:$typesafe_config_version"

View File

@ -1,76 +0,0 @@
Publishing Corda
================
Before Publishing
-----------------
Before publishing you must make sure the version you plan to publish has a unique version number. Jcenter and Maven
Central will not allow overwriting old versions _unless_ the version is a snapshot.
This guide assumes you are trying to publish to net.corda.*. Any other Maven coordinates require approval from Jcenter
and Maven Central.
Publishing Locally
------------------
To publish the codebase locally to Maven Local you must run:
.. code-block:: text
gradlew install
.. note:: This command is an alias for `publishToMavenLocal`.
Publishing to Jcenter
---------------------
.. note:: The module you wish to publish must be linked to jcenter in Bintray. Only the founding account can do this.
To publish to Jcenter you must first have the following;
1. An account on Bintray in the R3 organisation
2. Our GPG key's passphrase for signing the binaries to publish
Getting Setup
`````````````
You must now set the following environment variables:
* CORDA_BINTRAY_USER your Bintray username
* CORDA_BINTRAY_KEY to your Bintray API key (found at: https://bintray.com/profile/edit)
* CORDA_BINTRAY_GPG_PASSPHRASE to our GPG passphrase
Publishing
``````````
Once you are setup you can upload all modules in a project with
.. code-block:: text
gradlew bintrayUpload
Now login to Bintray and navigate to the corda repository, you will see a box stating you have published N files
and asking if you wish to publish. You can now publish to Bintray and Jcenter by clicking this button.
.. warning:: Before publishing you should check that all of the files are uploaded and are signed.
Within a minute your new version will be available to download and use.
Publishing to Maven Central
---------------------------
To publish to Maven Central you need the following;
1. An admin account on our Bintray R3 organisation
2. A published version in Bintray
3. An account with our Sonatype organisation (Maven Central's host)
Publishing
``````````
1. Publish to Bintray
2. Navigate to the project you wish to publish
3. Click "Maven Central"
4. Enter your Sonatype credentials to publish a new version
.. note:: The project you publish must be already published to Bintray and the project must be linked to Jcenter

View File

@ -6,5 +6,4 @@ Release process
release-notes
changelog
publishing-corda
codestyle

View File

@ -5,6 +5,7 @@ apply plugin: 'kotlin-jpa'
apply plugin: CanonicalizerPlugin
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda finance modules'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda node Artemis API'

View File

@ -2,6 +2,7 @@ apply plugin: 'kotlin'
apply plugin: 'kotlin-kapt'
apply plugin: 'idea'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda node database schemas'

View File

@ -5,6 +5,7 @@ apply plugin: 'kotlin-jpa'
apply plugin: 'java'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda node modules'

View File

@ -4,6 +4,7 @@
*/
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'us.kirchmeier.capsule'
apply plugin: 'com.jfrog.artifactory'
description 'Corda standalone node'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Testing utilities for Corda'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'net.corda.plugins.quasar-utils'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda verifier'

View File

@ -1,6 +1,7 @@
apply plugin: 'kotlin'
apply plugin: 'java'
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'com.jfrog.artifactory'
description 'Corda node web server'

View File

@ -4,6 +4,7 @@
*/
apply plugin: 'net.corda.plugins.publish-utils'
apply plugin: 'us.kirchmeier.capsule'
apply plugin: 'com.jfrog.artifactory'
description 'Corda node web server capsule'