How to pass/read Azure key vault secrets in Maven task of Azure Pipeline, to avoid saving credentials in code?
Are you trying to run the job on cloud?
Yes. While running on local, saving the user credentials in code was not an issue. But to run on cloud, I want to avoid this situation, for security purposes.
You can either use a variable group, by linking it with Azure Key Vault.
Or you can also use Azure Key Vault task.
Here are few documents to help you:
ok. But how to do it via Maven task?
In Maven task, use the below variable syntax:
- task: [email protected] inputs: mavenPomFile: $(SomeVariable) . .