crawly icon indicating copy to clipboard operation
crawly copied to clipboard

Make the management tool opt-in by default

Open aej opened this issue 2 years ago • 5 comments

I think it would be more convenient for the management tool to be removed by default from the application children and instead make it opt-in.

This would let library users who do not want to run the management tool at all, or who want to run the management tool in a different place (i.e inside another Plug-based application/supervision tree) be able to do so without unnecessarily running a webserver.

We can then instruct library users to simply add the Crawly.API.Router to their supervision tree with whatever configuration/plug-compatible webserver they choose.

# application.ex
defmodule MyApp.Application do
  use Application


  def start(_) do
    children = [
      ...
      {Plug.Cowboy, scheme: :http, plug: Crawly.API.Router}
      ...
    ]
  end
end

aej avatar May 20 '23 10:05 aej

I like the idea!

oltarasenko avatar May 22 '23 22:05 oltarasenko

Hey @aej I have tried to address this idea in the: https://github.com/elixir-crawly/crawly/pull/265

oltarasenko avatar Jun 19 '23 09:06 oltarasenko

Hey @aej I have tried to address this idea in the: #265

Fantastic - it looks good to me.

aej avatar Jun 19 '23 10:06 aej

Any chance of getting this released soon? Pretty please?

samullen avatar Aug 19 '23 13:08 samullen

Yes sure. There is no reason to keep it unreleased. let me prepare the release early this week

oltarasenko avatar Aug 21 '23 08:08 oltarasenko