Skip to content
This repository has been archived by the owner on Mar 17, 2024. It is now read-only.

property placeholder support in application.conf #474

Open
FrVaBe opened this issue Jun 15, 2023 · 2 comments
Open

property placeholder support in application.conf #474

FrVaBe opened this issue Jun 15, 2023 · 2 comments

Comments

@FrVaBe
Copy link

FrVaBe commented Jun 15, 2023

Enhancement
Support for property placeholders in application.conf.

One use case is to provide a standardized Kubernetes deployment for different systems.
In the systems themselves, only the bootstrap-brokers specification changes.
This could be set as an environment variable in the deployment. The environment variable would then be used in the application.conf and no system-specific configuration files would be required.

  clusters = [
    {
      name = "my-kafka-cluster"
      bootstrap-brokers = "${BOOTSTRAP_BROKERS}"
      topic-whitelist = [
        ".*"
      ]
      ....
	}
  ]

Additional context
If I missed something to support this use case in other ways, I would be glad to here about it.

@Philippus
Copy link

Philippus commented Jun 26, 2023

Maybe I'm missing something but this is already possible, we are using kafka-lag-exporter like this.
We have an application.conf with ${BOOTSTRAP_BROKERS} in the contents. BOOTSTRAP_SERVERS is further specified in our helm chart/application set.

@FrVaBe
Copy link
Author

FrVaBe commented Jun 27, 2023

Unfortunately, I don't know anything about helm. Is the property perhaps replaced by helm during the deployment? My use case is that the application.conf must be loaded by the kafka-lag-exporter with the property placeholder and the kafka-lag-exporter than replaces the property with the Environemt variable value. At least this did not work in my test.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants