diff options
Diffstat (limited to 'lib/chef_zero/server.rb')
-rw-r--r-- | lib/chef_zero/server.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/chef_zero/server.rb b/lib/chef_zero/server.rb index dd83fe3..43b42f8 100644 --- a/lib/chef_zero/server.rb +++ b/lib/chef_zero/server.rb @@ -287,9 +287,9 @@ module ChefZero :SSLEnable => options[:ssl], :SSLOptions => ssl_opts, :SSLCertName => [ [ "CN", WEBrick::Utils.getservername ] ], - :StartCallback => proc { + :StartCallback => proc do @running = true - } + end ) ENV["HTTPS"] = "on" if options[:ssl] @server.mount("/", Rack::Handler::WEBrick, app) @@ -320,9 +320,7 @@ module ChefZero end # Do not return until the web server is genuinely started. - while !@running && @thread.alive? - sleep(0.01) - end + sleep(0.01) while !@running && @thread.alive? SocketlessServerMap.instance.register_port(@port, self) |