From e245d9c5b532eea5bd4f650e63285f24bbbafe34 Mon Sep 17 00:00:00 2001 From: risson <18313093+rissson@users.noreply.github.com> Date: Tue, 11 Jul 2023 13:57:57 +0200 Subject: [PATCH] Allow optional IPv6 for clickhouse repo (#2970) * Allow optional IPv6 for clickhouse repo Signed-off-by: Marc 'risson' Schmitt * remove trailing comma --------- Signed-off-by: Marc 'risson' Schmitt Co-authored-by: ruslandoga --- config/runtime.exs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/config/runtime.exs b/config/runtime.exs index e7df29587..18b22fa0c 100644 --- a/config/runtime.exs +++ b/config/runtime.exs @@ -292,9 +292,14 @@ config :plausible, :google, reporting_api_url: "https://analyticsreporting.googleapis.com", max_buffer_size: get_int_from_path_or_env(config_dir, "GOOGLE_MAX_BUFFER_SIZE", 10_000) +maybe_ch_ipv6 = + get_var_from_path_or_env(config_dir, "ECTO_CH_IPV6", "false") + |> String.to_existing_atom() + ch_transport_opts = [ keepalive: true, - show_econnreset: true + show_econnreset: true, + inet6: maybe_ch_ipv6 ] config :plausible, Plausible.ClickhouseRepo,