The new configurator does not allow to override key/values by env
variables. It seems to support a framework property "configurator.initial"
though which could be given a list of files to read config from. Not sure
how well that matches kubernetes configMaps but I will try.

Christian

Am Do., 13. Sep. 2018 um 15:34 Uhr schrieb Raymond Auge <
raymond.a...@liferay.com>:

> I thought this is exactly what the new Configurator Specification [1] is
> all about.
>
> - Ray
>
> [1]
> https://osgi.org/specification/osgi.cmpn/7.0.0/service.configurator.html
>
>
> On Thu, Sep 13, 2018 at 8:30 AM, Christian Schneider <
> ch...@die-schneider.net> wrote:
>
> > I am looking into good ways to provide configuration to OSGi bundles for
> > cloud setups.
> >
> > So my prototypical application would be a self running jar created by
> > bndtools. This is then packaged into a docker image that simply runs the
> > jar. The docker image is then deployed using kubernetes. I got an example
> > of such an application from my adaptto talk about felix systemready. See
> > https://github.com/cschneider/osgi-example-systemready
> >
> > This is all well as long as all your config is inside the application
> > already or can be read using existing means like the hostnames provided
> by
> > kubernetes. For many cases this is not enough though.
> >
> > I can imagine to use env variables to override key/values of configs like
> > provided by the old configurer by Peter. I just created an issue to look
> > into this: https://issues.apache.org/jira/browse/FELIX-5924
> >
> > There are other possible ways though. For example kubernetes allows to
> map
> > configMaps to files which then could be fed into config admin. Did anyone
> > try this and ideally maybe has an example?
> >
> > Some interesting possible requirements:
> > - The config should be applied in a way that avoids oscillation of
> > services. So ideally config should be applied in one step
> > - Secrets should be protected in some way
> > - Kubernetes seems to be able to reflect updates to configMaps in a live
> > system. So this might be a case where we want to update config inside a
> > running app even in the cloud.
> >
> > So what are your ideas and approaches with applying configs to OSGi cloud
> > applications?
> >
> > Christian
> > --
> > --
> > Christian Schneider
> > http://www.liquid-reality.de
> >
> > Computer Scientist
> > http://www.adobe.com
> >
>
>
>
> --
> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
>  (@rotty3000)
> Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
>  (@Liferay)
> Board Member & EEG Co-Chair, OSGi Alliance <http://osgi.org>
> (@OSGiAlliance)
>


-- 
-- 
Christian Schneider
http://www.liquid-reality.de

Computer Scientist
http://www.adobe.com
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to