Updated logger to be more robust

This commit is contained in:
Sdogruyol 2015-11-18 22:45:49 +02:00
parent 639d4a7a48
commit 28d4d5167b
6 changed files with 39 additions and 16 deletions

View file

@ -7,7 +7,7 @@ at_exit do
Kemal.config.port = opt_port.to_i
end
opts.on("-e ", "--environment ", "environment") do |env|
env ? Kemal.config.env = env : "development"
Kemal.config.env = env
end
end
@ -17,9 +17,6 @@ at_exit do
config.add_handler HTTP::StaticFileHandler.new("./public")
server = HTTP::Server.new(config.port, config.handlers)
server.ssl = config.ssl
puts "Kemal is ready to lead at #{config.scheme}://0.0.0.0:#{config.port}"
server.listen
end