Closed imranismail closed 5 years ago
This is a deal breaker for us. We are still not confident to deploy distillery 2.0 because of this
How are you configuring Ecto? Would be handy to provide some more details on your config situation.
I am using the Elixir config provider for configuring our Ecto repos
On Thu, 11 Oct 2018, 3:32 pm Arjan Scherpenisse, notifications@github.com wrote:
How are you configuring Ecto? Would be handy to provide some more details on your config situation.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bitwalker/distillery/issues/568#issuecomment-428851160, or mute the thread https://github.com/notifications/unsubscribe-auth/AGkJPy2CJxkwFzLxuGjPlhRCSMqQORlmks5ujvPxgaJpZM4XW3MG .
Is the config provider reading from the network? Is it possible to output the value during running config provider phase?
How do I do that @aquarhead
I'm not using config providers (yet), so just wondering whether you can use IO.inspect
and check whether values exist at that point (first start). Or write out the values to another file (if stdout is not attachable)
I will set this up and report back.
But just to clarify I am not using any sort of config providers over the network.
I'm using the built in Elixir config provider.
Generated sys.config looks about right, however the config is not loaded.
@aquarhead @bitwalker I've confirmed this via attach
command after start
command.
Had to run the start
then attach
command combination several times to reproduce the error.
The results are
[
{App.Repo, [adapter: Ecto.Adapters.Postgres]}
]
When it should be as per sys.config
[
{App.Repo, [
adapter: Ecto.Adapters.Postgres,
username: "redacted",
password: "redacted",
hostname: "redacted",
database: "redacted",
pool_size: 10,
pool_overflow: 20,
port: 5432
]}
]
Any update on this?
I've left a couple of comments on https://github.com/bitwalker/distillery/issues/275#issuecomment-459664281 about a race condition with sys.config generation that seems to be related to the issue being discussed here.
This should no longer be an issue with the latest versions, a signficant amount has changed since this issue was first reported
Steps to reproduce
There are times where the app would boot up before the sys.config generation resolves.
And db_connection/ecto would complain about missing database config.
Rebooting the app resolves the issue.
Verbose Logs
Paste the output of the release command you ran with the
--verbose
flag below in the summary tags (this helps keep the issue easy to navigate):