Skip to content

Instantly share code, notes, and snippets.

@tanukesensei
Created November 23, 2022 14:37
Show Gist options
  • Save tanukesensei/9f7bbcef42ee96c804520f1c3294720f to your computer and use it in GitHub Desktop.
Save tanukesensei/9f7bbcef42ee96c804520f1c3294720f to your computer and use it in GitHub Desktop.
defmodule Friends.Application do
# See https://hexdocs.pm/elixir/Application.html
# for more information on OTP Applications
@moduledoc false
use Application
@impl true
def start(_type, _args) do
children = [
# Starts a worker by calling: Friends.Worker.start_link(arg)
# {Friends.Worker, arg}
]
# See https://hexdocs.pm/elixir/Supervisor.html
# for other strategies and supported options
opts = [strategy: :one_for_one, name: Friends.Supervisor]
Supervisor.start_link(children, opts)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment