class Falcon::Service::Application
def setup(container)
Setup instances of the application into the container.
def setup(container) protocol = self.protocol scheme = self.scheme run_options = { name: self.name, restart: true, } run_options[:count] = count unless count.nil? container.run(**run_options) do |instance| Async(logger: logger) do |task| Async.logger.info(self) {"Starting application server for #{self.root}..."} server = Server.new(self.middleware, @bound_endpoint, protocol: protocol, scheme: scheme) server.run instance.ready! task.children.each(&:wait) end end super end