Files
2026-07-04 19:27:17 +09:00

35 lines
1.0 KiB
Elixir

defmodule Rsh26pool.Application do
# See https://elixir.hexdocs.pm/Application.html
# for more information on OTP Applications
@moduledoc false
use Application
@impl true
def start(_type, _args) do
children = [
Rsh26poolWeb.Telemetry,
Rsh26pool.Repo,
{DNSCluster, query: Application.get_env(:rsh26pool, :dns_cluster_query) || :ignore},
{Phoenix.PubSub, name: Rsh26pool.PubSub},
# Periodically closes rooms that have reached their auto-end time.
Rsh26pool.RoomCloser,
# Start to serve requests, typically the last entry
Rsh26poolWeb.Endpoint
]
# See https://elixir.hexdocs.pm/Supervisor.html
# for other strategies and supported options
opts = [strategy: :one_for_one, name: Rsh26pool.Supervisor]
Supervisor.start_link(children, opts)
end
# Tell Phoenix to update the endpoint configuration
# whenever the application is updated.
@impl true
def config_change(changed, _new, removed) do
Rsh26poolWeb.Endpoint.config_change(changed, removed)
:ok
end
end