class Puma::DSL
def activate_control_app(url="auto", opts={})
@example
activate_control_app 'unix:///var/run/pumactl.sock', { auth_token: '12345' }
@example
activate_control_app 'unix:///var/run/pumactl.sock'
@example
Check out {Puma::App::Status} to see what the app has available.
simple authentication.
will need to include that token as a query parameter. This allows for
provide an authentication token, so all requests to the control server
be communicated with to control the main server. Additionally, you can
Start the Puma control rack application on +url+. This application can
def activate_control_app(url="auto", opts={}) if url == "auto" path = Configuration.temp_path @options[:control_url] = "unix://#{path}" @options[:control_url_temp] = path else @options[:control_url] = url end if opts[:no_token] # We need to use 'none' rather than :none because this value will be # passed on to an instance of OptionParser, which doesn't support # symbols as option values. # # See: https://github.com/puma/puma/issues/1193#issuecomment-305995488 auth_token = 'none' else auth_token = opts[:auth_token] auth_token ||= Configuration.random_token end @options[:control_auth_token] = auth_token @options[:control_url_umask] = opts[:umask] if opts[:umask] end