pik4
pik4

Reputation: 1373

Externalize configuration Akka

I am new in Akka and I faced the problem below.

I want to externalize the configuration in my App. More specifically, I have some variables that are different per each environment. So I think that I can have specific environment variables (secrets, etc) for each environment. But what I can do with some variables (non-secrets) which are different per each environment?

What is the difference between, dev.properties, application.conf, deploy.json files? What is the proper way to load variables from those files?

Upvotes: 1

Views: 2362

Answers (1)

johanandren
johanandren

Reputation: 11479

There's a few options:

If that is not enough you could also do completely custom logic around selecting logic by programmatically creating a Config instance and passing that to the ActorSystem when you create it.

The dev.properties and deploy.json is AFAIK not related to Akka, unless something specifically done in your application.

Upvotes: 2

Related Questions