anycable-thruster 0.1.16-x86_64-darwin → 0.1.18-x86_64-darwin
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
- data/README.md +35 -0
- data/exe/thrust +17 -2
- data/exe/x86_64-darwin/thrust +0 -0
- data/lib/anycable/thruster/version.rb +1 -1
- data/lib/thruster/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b232bfd1247eeedf347f9c30bf6c9ad84c778aba370f73edca4ad6866181aa1d
|
4
|
+
data.tar.gz: cf76b9ab8b33371de7f027b32402510e34778de49666a867624fb71615c103c5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f2bc3aed0ae8ac72b3c00773cffbbf7b45c7994b76bfa1ac9d6f1d9b2131ff2d3bfc550edbae73b6a2ac7ef47e5475566dca772a8d217f479b019716cb871f00
|
7
|
+
data.tar.gz: 06ba18e5975daaa9c31dba1bdd70d9cc797f2bda122c790fba738477f9e5a2346cfade0408bb480011c73e0b6365b16dc53abf3fb91e2376376c9a7f0a2f0624
|
data/README.md
CHANGED
@@ -26,6 +26,40 @@ ANYCABLE_DEBUG=true thrust bin/rails s
|
|
26
26
|
ANYCABLE_OPT="-debug" thrust bin/rails s
|
27
27
|
```
|
28
28
|
|
29
|
+
## Using a custom AnyCable binary
|
30
|
+
|
31
|
+
AnyCable Thruster can launch an external AnyCable-compatible binary (e.g., **AnyCable Pro**) instead of the one bundled with the gem.
|
32
|
+
Set `ANYCABLE_THRUSTER_BIN_PATH` to either a **full path** or a **command name** (looked up in `$PATH`).
|
33
|
+
If the variable is not set, Thruster falls back to the bundled per-platform binary.
|
34
|
+
|
35
|
+
### Local usage
|
36
|
+
|
37
|
+
If you have `anycable-thruster` available in your `$PATH`:
|
38
|
+
|
39
|
+
```sh
|
40
|
+
# Thruster will exec the given binary and pass through all CLI args
|
41
|
+
ANYCABLE_THRUSTER_BIN_PATH=anycable-thruster thrust bin/rails server
|
42
|
+
|
43
|
+
#You may also use an absolute path if you prefer:
|
44
|
+
ANYCABLE_THRUSTER_BIN_PATH=/usr/local/bin/anycable-thruster thrust bin/rails server
|
45
|
+
```
|
46
|
+
|
47
|
+
### Heroku (with the AnyCable Go buildpack)
|
48
|
+
|
49
|
+
**Configure the AnyCable Go buildpack to fetch the Thruster binary:**
|
50
|
+
- `HEROKU_ANYCABLE_GO_BINARY_NAME=anycable-thruster`
|
51
|
+
|
52
|
+
In Procfile:
|
53
|
+
|
54
|
+
```
|
55
|
+
# resolves via PATH
|
56
|
+
web: ANYCABLE_THRUSTER_BIN_PATH=anycable-thruster thrust bin/rails server
|
57
|
+
|
58
|
+
# resolve absolute path at runtime
|
59
|
+
# web: ANYCABLE_THRUSTER_BIN_PATH=$(which anycable-thruster) thrust bin/rails server
|
60
|
+
```
|
61
|
+
|
62
|
+
For full buildpack options see the buildpack [README](https://github.com/anycable/heroku-anycable-go).
|
29
63
|
----
|
30
64
|
|
31
65
|
> [!NOTE]
|
@@ -123,6 +157,7 @@ environment variables that you can set.
|
|
123
157
|
| `EAB_KID` | The EAB key identifier to use when provisioning TLS certificates, if required. | None |
|
124
158
|
| `EAB_HMAC_KEY` | The Base64-encoded EAB HMAC key to use when provisioning TLS certificates, if required. | None |
|
125
159
|
| `FORWARD_HEADERS` | Whether to forward X-Forwarded-* headers from the client. | Disabled when running with TLS; enabled otherwise |
|
160
|
+
| `LOG_REQUESTS` | Log all requests. Set to `0` or `false` to disable request logging | Enabled |
|
126
161
|
| `DEBUG` | Set to `1` or `true` to enable debug logging. | Disabled |
|
127
162
|
|
128
163
|
To prevent naming clashes with your application's own environment variables,
|
data/exe/thrust
CHANGED
@@ -1,11 +1,26 @@
|
|
1
1
|
#! /usr/bin/env ruby
|
2
2
|
|
3
|
-
|
3
|
+
ENV_KEY = "ANYCABLE_THRUSTER_BIN_PATH"
|
4
|
+
CUSTOM_ANYCABLE_PATH = ENV[ENV_KEY].to_s
|
5
|
+
|
6
|
+
if CUSTOM_ANYCABLE_PATH != ""
|
7
|
+
begin
|
8
|
+
exec(CUSTOM_ANYCABLE_PATH, *ARGV)
|
9
|
+
rescue Errno::ENOENT
|
10
|
+
warn("ERROR: #{ENV_KEY}=#{CUSTOM_ANYCABLE_PATH.inspect} not found in PATH or as a file.")
|
11
|
+
exit 1
|
12
|
+
rescue SystemCallError => e
|
13
|
+
warn("ERROR: #{ENV_KEY}=#{CUSTOM_ANYCABLE_PATH.inspect} failed: #{e.class}: #{e.message}")
|
14
|
+
exit 1
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
PLATFORM = %i[cpu os].map { |m| Gem::Platform.local.send(m) }.join("-")
|
4
19
|
EXECUTABLE = File.expand_path(File.join(__dir__, PLATFORM, "thrust"))
|
5
20
|
|
6
21
|
if File.exist?(EXECUTABLE)
|
7
22
|
exec(EXECUTABLE, *ARGV)
|
8
23
|
else
|
9
|
-
|
24
|
+
warn("ERROR: Unsupported platform: #{PLATFORM}")
|
10
25
|
exit 1
|
11
26
|
end
|
data/exe/x86_64-darwin/thrust
CHANGED
Binary file
|
data/lib/thruster/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: anycable-thruster
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.18
|
5
5
|
platform: x86_64-darwin
|
6
6
|
authors:
|
7
7
|
- Kevin McConnell
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
- Igor Platonov
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: A zero-config HTTP/2 proxy for lightweight production deployments with
|
15
15
|
AnyCable real-time server included
|
@@ -46,7 +46,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0'
|
48
48
|
requirements: []
|
49
|
-
rubygems_version: 3.6.
|
49
|
+
rubygems_version: 3.6.9
|
50
50
|
specification_version: 4
|
51
51
|
summary: Zero-config HTTP/2 proxy with embedded AnyCable
|
52
52
|
test_files: []
|