mirror of
https://github.com/corda/corda.git
synced 2024-12-24 07:06:44 +00:00
CORDA-742 Added constant for cache directory.
This commit is contained in:
parent
8021cdd364
commit
a3c553d44a
@ -183,7 +183,7 @@ open class Cordform : DefaultTask() {
|
||||
// InheritIO causes hangs on windows due the gradle buffer also not being flushed.
|
||||
// Must redirect to output or logger (node log is still written, this is just startup banner)
|
||||
.redirectOutput(node.logFile().toFile())
|
||||
.addEnvironment("CAPSULE_CACHE_DIR", "./cache")
|
||||
.addEnvironment("CAPSULE_CACHE_DIR", capsuleCacheDir)
|
||||
.start()
|
||||
return Pair(node, process)
|
||||
}
|
||||
@ -191,7 +191,7 @@ open class Cordform : DefaultTask() {
|
||||
private fun generateNodeInfoCommand(): List<String> = listOf(
|
||||
"java",
|
||||
"-Dcapsule.log=verbose",
|
||||
"-Dcapsule.dir=./cache",
|
||||
"-Dcapsule.dir=$capsuleCacheDir",
|
||||
"-jar",
|
||||
Node.nodeJarName,
|
||||
"--just-generate-node-info"
|
||||
@ -225,6 +225,7 @@ open class Cordform : DefaultTask() {
|
||||
}
|
||||
}
|
||||
|
||||
private const val capsuleCacheDir: String = "./cache"
|
||||
private fun Node.fullPath(): Path = project.projectDir.toPath().resolve(this.nodeDir.toPath())
|
||||
private fun Node.logDirectory(): Path = this.fullPath().resolve("logs")
|
||||
private fun Node.makeLogDirectory() = Files.createDirectories(this.logDirectory())
|
||||
|
Loading…
Reference in New Issue
Block a user