ml-gradle
ml-gradle copied to clipboard
Deploy Cert auth, templates AND host certificates
mlDeploySecurity does all three (and a lot more), but you cannot do all three separately. You can mlDeployCertificateAuthorities, and mlDeployCertificateTemplates, but no mlDeployHostCertificates (to match the underlying command InsertCertificateHostsTemplateCommand).
Is there a workaround (using build.gradle only) and/or can this be added?
@grtjn This looks like an oversight. I don't see any reason why the InsertCertificateHostsTemplateCommand
can't be run in isolation. I'll add it to the next release.
In the meantime, you can make a custom task like this (which I thought was documented somewhere but I'm not seeing it, so I'll get it documented as part of this ticket too):
task myTask(type: com.marklogic.gradle.task.MarkLogicTask) {
doLast {
new com.marklogic.appdeployer.command.security.InsertCertificateHostsTemplateCommand().execute(getCommandContext())
}
}
You could potentially consider attaching it to mlDeployCertificateTemplates, but a separate task would be useful too.
Thinking this task should be named mlDeployHostCertificateTemplates
. I believe the term "Insert" was chosen to coincide with how the Manage API uses the term "insertHC" in this context, but that would be unexpected to an ml-gradle user.
Being resolved via #641