Search code examples
blockchainkeystorecorda

How do we reuse the nodekeystore.jks generated by X509Utilities in Corda network?


In our corda project we are running the nodes in devmode. Every time we do some changes in the flow implementation we re-deploy the nodes with the help of ./gradlew clean deployNodes command in our dev environment.

So as part of the requirements we need to have a constant public key for a set of flows to work. but every time we redeploy with the above command a new set of truststore.jks nodekeystore.jks sslkeystore.jks is generated for each node .

How can we reuse these self signed certificates generated by X509Utilities so that we can utilize the same nodekeystore.jks which would result in the same public key in every build of the nodes.


Solution

  • Instead of using ./gradlew deployNodes which rebuilds everything, you can simply rebuild a certain module using ./gradlew :module-name:build.