It sounds interesting. Does it also support replacement with "system variables" (like -Duser=my-user) ?
I started a ConfigAdmin "hack" for Karaf about that, especially when running in Docker. Regards JB On 11/06/2019 14:30, [email protected] wrote: > Hi all, > > Some time ago I wrote a small bundle that provides a Configuration Admin > plugin to substitute placeholders in configuration items with values > obtained from the local file system. It was initially developed to obtain > Kubernetes secrets, which surface as local files in the running container. > > For example, a configuration PID could be configured in ConfigAdmin like > this: > com.my.database: > "user": "my-user", > "password": "$[secret:db.password]" > > With this plugin configured, the value for password is picked up by the > Configuration Admin plugin from a local file called 'db.password'. The > entire content of the file is used as value. The file itself can be found > in a configurable location. > > The bundle is quite simple, and while I developed it for a K8s use-case it > does not have any K8s dependencies, and would probably also apply to other > use-cases, maybe with some modifications or enhancements. > What do you think? Would this be an interesting contribution to the Felix > codebase? > > Best regards, > > David Bosschaert > -- Jean-Baptiste Onofré [email protected] http://blog.nanthrax.net Talend - http://www.talend.com
