Reputation: 13
I have my keystore password saved on the server, which I am pulling from a vault. I want to provide a path to quarkus.http.ssl.certificate.key-store-password instead of a hardcoded password. Do we have any interceptors before the start so that password can be loaded from that file using some @override implementation?
Or some other approach to this. I don't want to put the password file in the project. I want to provide the path in the application.yaml.
Quarkus 2.7
Upvotes: 0
Views: 260
Reputation: 167
You can use the Vault extension https://quarkus.io/extensions/io.quarkiverse.vault/quarkus-vault/
Or if you want, you can setup the yaml file to access the keystore password file from an environment variable
yaml:
quarkus:
http:
ssl:
certificate:
key-store-password: ${KEYSTORE_PASSWORD_ENV_VAR}
Before starting the application, export the environment variable like this:
export KEYSTORE_PASSWORD_ENV_VAR=$(cat /path/to/keystore/password/file)
Let me know if this works
Upvotes: 1