I haven’t noticed an issue when visiting or using our site, https://metamorphic.app.
However, some people have stated that they receive an error when using s6-dnsip
to try and look up the dns info for the domain metamorphic.app
:
s6-dnsip metamorphic.app
s6-dnsip: fatal: : unable to resolve metamorphic.app: no such domain
I was curious if this is a misconfiguration error on my end or something else? It’s an Elixir/Phoenix app and here is my runtime.exs
configuration:
# Configure the canonical host for redirects.
config :metamorphic, canonical_host: host
config :metamorphic, MetamorphicWeb.Endpoint,
url: [host: host, port: 443, scheme: "https"],
force_ssl: [rewrite_on: [:x_forwarded_proto]],
live_view: [
signing_salt: System.get_env("LIVE_VIEW_SIGNING_SALT"),
encryption_salt: System.get_env("LIVE_VIEW_ENCRYPTION_SALT")
],
http: [
# Enable IPv6 and bind on all interfaces.
# Set it to {0, 0, 0, 0, 0, 0, 0, 1} for local network only access.
# See the documentation on https://hexdocs.pm/plug_cowboy/Plug.Cowboy.html
# for details about using IPv6 vs IPv4 and loopback vs public addresses.
ip: {0, 0, 0, 0, 0, 0, 0, 0},
port: port
],
secret_key_base: secret_key_base
# Configure libcluster for clustering
app_name =
System.get_env("FLY_APP_NAME") ||
raise "FLY_APP_NAME not available"
config :libcluster,
debug: true,
topologies: [
fly6pn: [
strategy: Cluster.Strategy.DNSPoll,
config: [
polling_interval: 5_000,
query: "#{app_name}.internal",
node_basename: app_name
]
]
]
And my fly.toml
:
# fly.toml app configuration file generated for metamorphic on 2023-07-19T17:58:18-04:00
#
# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
#
app = "metamorphic"
primary_region = "bos"
kill_signal = "SIGTERM"
[deploy]
release_command = "/app/bin/migrate"
[env]
PHX_HOST = "metamorphic.app"
PORT = "8080"
PRIMARY_REGION="bos"
RELEASE_COOKIE="1a3LEqcIUmDIK-GNMeH1MQGRaNvnfIny4MSmqsk85kv7Zh1Z35tVgg=="
[[services]]
protocol = "tcp"
internal_port = 8080
processes = ["app"]
[[services.ports]]
port = 443
handlers = ["tls", "http"]
[services.concurrency]
type = "connections"
hard_limit = 25
soft_limit = 20
[[services.tcp_checks]]
interval = "15s"
timeout = "2s"
grace_period = "1s"
restart_limit = 0
Oh also my env.sh.eex
:
#!/bin/sh
# configure node for distributed erlang with IPV6 support
export ERL_AFLAGS="-proto_dist inet6_tcp"
export ECTO_IPV6="true"
export DNS_CLUSTER_QUERY="${FLY_APP_NAME}.internal"
ip=$(grep fly-local-6pn /etc/hosts | cut -f 1)
export RELEASE_DISTRIBUTION=name
export RELEASE_NODE=$FLY_APP_NAME@$ip