toro v0.4.1 Release Notes

Release Date: 2018-07-02 // over 3 years ago

Previous changes from v0.4.0

  • If App is an instance of Toro, then you can start the server
    by calling App.run. You can pass any options you would use with
    the HTTP::Server constructor from the standard library.

    For example, you can start the server on port 80:

    App.run(80)
    

    ๐Ÿ”ง Or you can further configure server by using a block. The following
    ๐Ÿ”ง example shows how to configure SSL certificates:

    App.run(443) do |server| ssl = OpenSSL::SSL::Context::Server.new ssl.private\_key = "path/to/private\_key" ssl.certificate\_chain = "path/to/certificate\_chain" server.tls = sslend
    

    ๐Ÿ“š Refer to Crystal's documentation for more options.