Skip to content

Commit

Permalink
Start Phoenix endpoint last
Browse files Browse the repository at this point in the history
  • Loading branch information
ku1ik committed Jul 18, 2023
1 parent 529ea1e commit bf4a55a
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions lib/asciinema/application.ex
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,18 @@ defmodule Asciinema.Application do
Asciinema.Telemetry,
# Start the Ecto repository
Asciinema.Repo,
# Start rate limiter
{PlugAttack.Storage.Ets, name: AsciinemaWeb.PlugAttack.Storage, clean_period: 60_000},
# Start the endpoint when the application starts
AsciinemaWeb.Endpoint,
# Start PNG generator poolboy pool
:poolboy.child_spec(:worker, Asciinema.PngGenerator.Rsvg.poolboy_config(), []),
# Start Oban
{Oban, oban_config()},
# Start distributed registry
{Horde.Registry,
[name: Asciinema.Streaming.LiveStreamRegistry, keys: :unique, members: :auto]},
Asciinema.Streaming.LiveStreamSupervisor
Asciinema.Streaming.LiveStreamSupervisor,
# Start rate limiter
{PlugAttack.Storage.Ets, name: AsciinemaWeb.PlugAttack.Storage, clean_period: 60_000},
# Start the endpoint when the application starts
AsciinemaWeb.Endpoint
]

# See https://hexdocs.pm/elixir/Supervisor.html
Expand Down

0 comments on commit bf4a55a

Please sign in to comment.