2022-10-13 00:04:51 +02:00
|
|
|
import static org.gradle.api.JavaVersion.VERSION_11
|
|
|
|
|
|
|
|
plugins {
|
|
|
|
id 'org.jetbrains.kotlin.jvm'
|
|
|
|
id 'net.corda.cordapp.cordapp-configuration'
|
|
|
|
id 'org.jetbrains.kotlin.plugin.jpa'
|
|
|
|
id 'java'
|
|
|
|
id 'maven-publish'
|
2023-04-11 18:25:31 +02:00
|
|
|
id 'net.corda.plugins.csde'
|
2022-10-13 00:04:51 +02:00
|
|
|
}
|
|
|
|
|
2023-01-05 15:15:40 +01:00
|
|
|
allprojects {
|
2023-01-27 17:24:53 +01:00
|
|
|
group 'com.r3.developers.csdetemplate'
|
2023-01-05 15:15:40 +01:00
|
|
|
version '1.0-SNAPSHOT'
|
2022-10-13 00:04:51 +02:00
|
|
|
|
2023-01-05 15:15:40 +01:00
|
|
|
def javaVersion = VERSION_11
|
2022-10-13 00:04:51 +02:00
|
|
|
|
2023-04-11 18:25:31 +02:00
|
|
|
// Configure the CSDE
|
|
|
|
csde {
|
|
|
|
cordaClusterURL = "https://localhost:8888"
|
|
|
|
networkConfigFile = "config/static-network-config.json"
|
|
|
|
corDappCpiName = "MyCorDapp"
|
|
|
|
notaryCpiName = "NotaryServer"
|
|
|
|
cordaRpcUser = "admin"
|
|
|
|
cordaRpcPasswd ="admin"
|
|
|
|
csdeWorkspaceDir = "workspace"
|
|
|
|
notaryVersion = cordaNotaryPluginsVersion
|
|
|
|
combinedWorkerVersion = "5.0.0.0-Gecko1.0"
|
|
|
|
postgresJdbcVersion = "42.4.3"
|
|
|
|
cordaDbContainerName = "CSDEpostgresql"
|
|
|
|
cordaBinDir = "${System.getProperty("user.home")}/.corda/corda5"
|
|
|
|
cordaCliBinDir = "${System.getProperty("user.home")}/.corda/cli"
|
|
|
|
}
|
|
|
|
|
2023-01-05 15:15:40 +01:00
|
|
|
// Declare the set of Java compiler options we need to build a CorDapp.
|
|
|
|
tasks.withType(JavaCompile) {
|
|
|
|
// -parameters - Needed for reflection and serialization to work correctly.
|
|
|
|
options.compilerArgs += [
|
|
|
|
"-parameters"
|
|
|
|
]
|
2022-10-13 00:04:51 +02:00
|
|
|
}
|
2022-10-13 18:50:50 +02:00
|
|
|
|
2023-01-05 15:15:40 +01:00
|
|
|
repositories {
|
|
|
|
// All dependencies are held in Maven Central
|
2023-04-11 18:25:31 +02:00
|
|
|
mavenLocal()
|
2023-01-05 15:15:40 +01:00
|
|
|
mavenCentral()
|
2023-04-11 18:25:31 +02:00
|
|
|
|
|
|
|
// R3 Internal repositories for dev
|
|
|
|
// Repository provides Corda 5 binaries that implement Corda-API.
|
|
|
|
// These will be made publicly available.
|
|
|
|
// Final location to be decided.
|
|
|
|
// Repository subject to change
|
2023-03-16 19:29:57 +01:00
|
|
|
maven {
|
2023-04-11 18:25:31 +02:00
|
|
|
url = "$artifactoryContextUrl/corda-os-maven"
|
|
|
|
authentication {
|
|
|
|
basic(BasicAuthentication)
|
|
|
|
}
|
|
|
|
credentials {
|
|
|
|
username = findProperty('cordaArtifactoryUsername') ?: System.getenv('CORDA_ARTIFACTORY_USERNAME')
|
|
|
|
password = findProperty('cordaArtifactoryPassword') ?: System.getenv('CORDA_ARTIFACTORY_PASSWORD')
|
|
|
|
}
|
2023-03-16 19:29:57 +01:00
|
|
|
}
|
2022-10-14 14:20:24 +02:00
|
|
|
}
|
2022-10-13 00:04:51 +02:00
|
|
|
|
2023-01-05 15:15:40 +01:00
|
|
|
tasks.withType(Test).configureEach {
|
|
|
|
useJUnitPlatform()
|
|
|
|
}
|
2022-10-13 00:04:51 +02:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
publishing {
|
|
|
|
publications {
|
2023-01-05 15:15:40 +01:00
|
|
|
maven(MavenPublication) {
|
|
|
|
artifactId "corda-CSDE-java-sample"
|
|
|
|
groupId project.group
|
|
|
|
artifact jar
|
2022-10-13 00:04:51 +02:00
|
|
|
}
|
2023-01-10 10:57:15 +01:00
|
|
|
|
|
|
|
}
|
2022-10-13 00:04:51 +02:00
|
|
|
}
|
2023-01-05 15:15:40 +01:00
|
|
|
|