class Runcobo::Server
- Runcobo::Server
- Reference
- Object
Defined in:
runcobo/server.crConstructors
Class Method Summary
-
.default_handlers : Array(HTTP::Handler)
Set Default handlers, you can change them by
#handlers=
afterinitialize
.
Instance Method Summary
-
#cert : String?
SSL Certificate file.
-
#cert=(cert : String?)
SSL Certificate file.
-
#client : HTTP::Client
Creates a client for server.
-
#close : Nil
Closes server.
-
#generate_tls_context(certificate_chain : String, private_key : String) : OpenSSL::SSL::Context::Server
Generate TLS context with certificate_chain and private_key
-
#handlers : Array(HTTP::Handler)
Handlers, defaults to
.default_handlers
. -
#handlers=(handlers : Array(HTTP::Handler))
Handlers, defaults to
.default_handlers
. -
#host : String
Host, defaults to "0.0.0.0".
-
#host=(host : String)
Host, defaults to "0.0.0.0".
-
#instance : HTTP::Server
Server instance.
-
#key : String?
SSL key file.
-
#key=(key : String?)
SSL key file.
- #listen
-
#port : Int32
Port, defaults to 3000.
-
#port=(port : Int32)
Port, defaults to 3000.
-
#reuse_port : Bool
Reuse Port, defaults to false.
-
#reuse_port=(reuse_port : Bool)
Reuse Port, defaults to false.
Constructor Detail
Class Method Detail
Set Default handlers, you can change them by #handlers=
after initialize
.
Instance Method Detail
def generate_tls_context(certificate_chain : String, private_key : String) : OpenSSL::SSL::Context::Server
#
Generate TLS context with certificate_chain and private_key
Handlers, defaults to .default_handlers
.