sidekiq_alive 2.0.4 → 2.0.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bbf273df09ffb9644877ecc5966a9c7e94615d491b13a79c8b1dc50a298188cd
4
- data.tar.gz: f5f6aed93f4504d8ddb2b0b38a24841a93110e09392d08d8e5639458cf505e85
3
+ metadata.gz: e6d5a90f1ac023c49440e1e24d53e05bd3fe1f5362822e125a8989981e51846e
4
+ data.tar.gz: dd90cc1b6d7b1fc6273426e32f950d68a71eaa7d63b42b32d914450f35eec09a
5
5
  SHA512:
6
- metadata.gz: 18a60ff3d82051ca24831b886a7b1a98be6c8121f89d13a25fc2b875357de615afd6620a80e9ed36f99d4b5b48a48eb3172f01548306d7658fcb0f80650d0ec8
7
- data.tar.gz: 7365d0aadc34ea188ff9a268222e2c7b7d21840f527f5444653fba72f9fdb3cd5184c5268b66590e8d2f8bacac85884c2a7ed7b0423d9920654372066fc37f58
6
+ metadata.gz: 533ef08f31e90ac4743577c561f3994c2b2e7eb9945cadcc4dc70dda3e2b339d8d8e6ab2d270b82a65dc884812b8d30ce1de49e50648af1a4136eafa77ee9dd3
7
+ data.tar.gz: 702c96b61ecaa7595b44ff9bd3dcfa29d58e99623a5fcd5534b94221dd92e96b06e0e81f217c826f7d8ee9e75bee55ef063d93ff855381efa5ead8af96a01cc4
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sidekiq_alive (2.0.4)
4
+ sidekiq_alive (2.0.5)
5
5
  sidekiq
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -196,6 +196,13 @@ curl localhost:7433
196
196
 
197
197
  ```ruby
198
198
  SidekiqAlive.setup do |config|
199
+ # ==> Server host
200
+ # Host to bind the server.
201
+ # Can also be set with the environment variable SIDEKIQ_ALIVE_HOST.
202
+ # default: 0.0.0.0
203
+ #
204
+ # config.host = 0.0.0.0
205
+
199
206
  # ==> Server port
200
207
  # Port to bind the server.
201
208
  # Can also be set with the environment variable SIDEKIQ_ALIVE_PORT.
@@ -4,7 +4,8 @@ module SidekiqAlive
4
4
  class Config
5
5
  include Singleton
6
6
 
7
- attr_accessor :port,
7
+ attr_accessor :host,
8
+ :port,
8
9
  :path,
9
10
  :liveness_key,
10
11
  :time_to_live,
@@ -18,6 +19,7 @@ module SidekiqAlive
18
19
  end
19
20
 
20
21
  def set_defaults
22
+ @host = ENV['SIDEKIQ_ALIVE_HOST'] || '0.0.0.0'
21
23
  @port = ENV['SIDEKIQ_ALIVE_PORT'] || 7433
22
24
  @path = ENV['SIDEKIQ_ALIVE_PATH'] || '/'
23
25
  @liveness_key = 'SIDEKIQ::LIVENESS_PROBE_TIMESTAMP'
@@ -10,7 +10,11 @@ module SidekiqAlive
10
10
 
11
11
  Signal.trap('TERM') { handler.shutdown }
12
12
 
13
- handler.run(self, Port: port, Host: '0.0.0.0')
13
+ handler.run(self, Port: port, Host: host)
14
+ end
15
+
16
+ def host
17
+ SidekiqAlive.config.host
14
18
  end
15
19
 
16
20
  def port
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SidekiqAlive
4
- VERSION = '2.0.4'
4
+ VERSION = '2.0.5'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq_alive
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.4
4
+ version: 2.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Artur Pañach
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-11-04 00:00:00.000000000 Z
11
+ date: 2021-03-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler