falcon 0.55.1 → 0.55.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/context/deployment.md +51 -5
- data/lib/falcon/body/request_finished.rb +1 -1
- data/lib/falcon/service/server.rb +0 -1
- data/lib/falcon/version.rb +1 -1
- data/license.md +1 -0
- data/readme.md +4 -4
- data/releases.md +4 -0
- data.tar.gz.sig +0 -0
- metadata +2 -1
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 3e901867477864a82832904cbaa1662105e6dce12190e057d457a666fa3dfe42
|
|
4
|
+
data.tar.gz: 523e181a6685bfe398bc5630076ab8e76642bf47181d4e20c62192813f121712
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0eb64a874478507caeafefb4c83b108cfa7b00326cf69ce7581ab534e9466048dea1572b66044f06ee19b21998fafad32cf5de3ea050f6ae0f32b1743424ef2e
|
|
7
|
+
data.tar.gz: 3f041a4ebdf07b1063373a27e7151b4f8380f4f440b34a773f27b0b6761d64f721209c5a7d2366f1210e1be1d3042d1e8bed117a77a7ce81d9335274636fe656
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
data/context/deployment.md
CHANGED
|
@@ -56,18 +56,22 @@ service "supervisor" do
|
|
|
56
56
|
end
|
|
57
57
|
~~~
|
|
58
58
|
|
|
59
|
-
These configuration blocks are evaluated using the [async-service](https://github.com/socketry/async-service) gem.
|
|
59
|
+
These configuration blocks are evaluated using the [async-service](https://github.com/socketry/async-service) gem. This configuration will bind Falcon to an [IPC socket](https://en.wikipedia.org/wiki/Unix_domain_socket) and is designed to be used with a reverse proxy such as [`falcon virtual`](#falcon-virtual).
|
|
60
|
+
|
|
61
|
+
The supervisor is an independent service which monitors the health of the application and can restart it if necessary. Other services like background job processors can be added to the configuration.
|
|
60
62
|
|
|
61
63
|
### Environments
|
|
62
64
|
|
|
63
65
|
The service blocks define configuration that is loaded by the service layer to control how the service is run. The `service ... do` block defines the service name and the environment in which it runs. Different modules can be included to provide different functionality, such as `Falcon::Environment::Rack` for Rack applications, or `Falcon::Environment::LetsEncryptTLS` for automatic TLS certificate management.
|
|
64
66
|
|
|
67
|
+
**NOTE**: Falcon does not provision or renew certificates automatically. Use a tool like [certbot](https://certbot.eff.org) to provision your certificate and the `LetsEncryptTLS` environment will automatically read it in.
|
|
68
|
+
|
|
65
69
|
### Application Configuration
|
|
66
70
|
|
|
67
71
|
The environment configuration is defined in the `Falcon::Environment` module. The {ruby Falcon::Environment::Application} environment supports the generic virtual host functionality, but you can customise any parts of the configuration, e.g. to bind a production host to `localhost:3000` using plaintext HTTP/2:
|
|
68
72
|
|
|
69
73
|
~~~ ruby
|
|
70
|
-
#!/usr/bin/env falcon
|
|
74
|
+
#!/usr/bin/env falcon-host
|
|
71
75
|
# frozen_string_literal: true
|
|
72
76
|
|
|
73
77
|
require "falcon/environment/rack"
|
|
@@ -76,12 +80,54 @@ require "async/service/supervisor"
|
|
|
76
80
|
hostname = File.basename(__dir__)
|
|
77
81
|
service hostname do
|
|
78
82
|
include Falcon::Environment::Rack
|
|
79
|
-
include Falcon::Environment::LetsEncryptTLS
|
|
80
83
|
|
|
81
84
|
endpoint do
|
|
82
85
|
Async::HTTP::Endpoint
|
|
83
86
|
.parse('http://localhost:3000')
|
|
84
|
-
.with(
|
|
87
|
+
.with(
|
|
88
|
+
protocol: Async::HTTP::Protocol::HTTP2
|
|
89
|
+
)
|
|
90
|
+
end
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
service "supervisor" do
|
|
94
|
+
include Async::Service::Supervisor::Environment
|
|
95
|
+
end
|
|
96
|
+
~~~
|
|
97
|
+
|
|
98
|
+
You can verify this is working using the [`nghttp2` client](https://nghttp2.org): `nghttp -v http://localhost:3000`. This will not work in a browser as they mandate TLS for HTTP/2 connections.
|
|
99
|
+
|
|
100
|
+
#### Self-signed certificate
|
|
101
|
+
|
|
102
|
+
You can use a self-signed certificate to test your server configuration locally. First, provision a certificate using the [`localhost` gem](https://github.com/socketry/localhost):
|
|
103
|
+
|
|
104
|
+
```
|
|
105
|
+
$ bundle exec bake localhost:install
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
You may be prompted for a password to install the certificate. This is the password for your local keychain.
|
|
109
|
+
|
|
110
|
+
Then, add the `SelfSignedTLS` environment to your configuration and set up the SSL context:
|
|
111
|
+
|
|
112
|
+
~~~ ruby
|
|
113
|
+
#!/usr/bin/env falcon-host
|
|
114
|
+
# frozen_string_literal: true
|
|
115
|
+
|
|
116
|
+
require "falcon/environment/rack"
|
|
117
|
+
require "async/service/supervisor"
|
|
118
|
+
|
|
119
|
+
hostname = File.basename(__dir__)
|
|
120
|
+
service hostname do
|
|
121
|
+
include Falcon::Environment::Rack
|
|
122
|
+
include Falcon::Environment::SelfSignedTLS
|
|
123
|
+
|
|
124
|
+
endpoint do
|
|
125
|
+
Async::HTTP::Endpoint
|
|
126
|
+
.parse('https://localhost:3000')
|
|
127
|
+
.with(
|
|
128
|
+
protocol: Async::HTTP::Protocol::HTTP2,
|
|
129
|
+
ssl_context: ssl_context
|
|
130
|
+
)
|
|
85
131
|
end
|
|
86
132
|
end
|
|
87
133
|
|
|
@@ -90,7 +136,7 @@ service "supervisor" do
|
|
|
90
136
|
end
|
|
91
137
|
~~~
|
|
92
138
|
|
|
93
|
-
You
|
|
139
|
+
You should now be able to access your server at `https://localhost:3000` in your browser.
|
|
94
140
|
|
|
95
141
|
#### Application Configuration Example for Heroku
|
|
96
142
|
|
data/lib/falcon/version.rb
CHANGED
data/license.md
CHANGED
|
@@ -28,6 +28,7 @@ Copyright, 2024, by Ismael Celis.
|
|
|
28
28
|
Copyright, 2025, by Pierre Montelle.
|
|
29
29
|
Copyright, 2025, by Jared Smith.
|
|
30
30
|
Copyright, 2025, by Yoji Shidara.
|
|
31
|
+
Copyright, 2026, by Ayush Newatia.
|
|
31
32
|
|
|
32
33
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
33
34
|
of this software and associated documentation files (the "Software"), to deal
|
data/readme.md
CHANGED
|
@@ -47,6 +47,10 @@ Please see the [project documentation](https://socketry.github.io/falcon/) for m
|
|
|
47
47
|
|
|
48
48
|
Please see the [project releases](https://socketry.github.io/falcon/releases/index) for all releases.
|
|
49
49
|
|
|
50
|
+
### v0.55.2
|
|
51
|
+
|
|
52
|
+
- Remove unnecessary require for `async/service/supervisor/supervised`."
|
|
53
|
+
|
|
50
54
|
### v0.55.1
|
|
51
55
|
|
|
52
56
|
- `requests_active` is decremented after the response body is closed, including `rack.response_finished` callbacks.
|
|
@@ -92,10 +96,6 @@ Please see the [project releases](https://socketry.github.io/falcon/releases/ind
|
|
|
92
96
|
- [Falcon Server Container Health Checks](https://socketry.github.io/falcon/releases/index#falcon-server-container-health-checks)
|
|
93
97
|
- [Falcon Server Process Title](https://socketry.github.io/falcon/releases/index#falcon-server-process-title)
|
|
94
98
|
|
|
95
|
-
### v0.48.4
|
|
96
|
-
|
|
97
|
-
- Improve compatibility of rackup handler w.r.t. sinatra.
|
|
98
|
-
|
|
99
99
|
## Contributing
|
|
100
100
|
|
|
101
101
|
We welcome contributions to this project.
|
data/releases.md
CHANGED
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: falcon
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.55.
|
|
4
|
+
version: 0.55.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Samuel Williams
|
|
@@ -15,6 +15,7 @@ authors:
|
|
|
15
15
|
- Peter Schrammel
|
|
16
16
|
- Sho Ito
|
|
17
17
|
- Adam Daniels
|
|
18
|
+
- Ayush Newatia
|
|
18
19
|
- Colby Swandale
|
|
19
20
|
- Daniel Evans
|
|
20
21
|
- Ismael Celis
|
metadata.gz.sig
CHANGED
|
Binary file
|