rorvswild 1.5.15 → 1.5.16

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: 29d23fa806fe2d9547169a35795b4b313bf7510264aba4d0f8f3471ae7acf047
4
- data.tar.gz: 681d88bef1fb76ede952387ef1d8ffbdf4bfa4cbf08f990f7964624401ff71a9
3
+ metadata.gz: ffb6ec6265892f727afe8fe18df63993e111da43c2e9cace51a3836c478988ca
4
+ data.tar.gz: e13d2690d2b9a9cfd771542092e22d88759f8cf554d2480e18edc8277f204a1d
5
5
  SHA512:
6
- metadata.gz: e54dba0143bdb8e94677519698857c7ddc62f91ecb0a876ecc9e0e2fb402e4d11055a59f03cca1c2ca5a2e73b82cf5380574d9e3e4c73d1a66e21c7ea54cfe6c
7
- data.tar.gz: 92d4cb2e15015929ccc609b6b81837fb1a78ea12ebe4538555e0a023266fc852001d1aa17d7e620b50dd6ac3f856cbf08bba1d3cb9e4f24f10333b1faa26064d
6
+ metadata.gz: 85df854f496092f2438769c82a6d1ab568743f47a0d684d9db564289cd8b022412e0cf9ec9629cfb5652a1666f5ec15c054f4ce6dba3da2af067141d4343a9c8
7
+ data.tar.gz: 736abc9c08a7970086daabc8c29c2272745a4cc37df53fe90362000fbcdbe61d4e2272f1b9db9d01a04e912bcc1b34f81281ce025ce13d75142fb6d35c87f2b7
@@ -159,6 +159,17 @@ module RorVsWild
159
159
  @os_description = RbConfig::CONFIG["host_os"]
160
160
  end
161
161
 
162
+ def hostname
163
+ if gae_instance = ENV["GAE_INSTANCE"] || ENV["CLOUD_RUN_EXECUTION"]
164
+ gae_instance
165
+ elsif dyno = ENV["DYNO"] # Heroku
166
+ dyno.start_with?("run.") ? "run.*" :
167
+ dyno.start_with?("release.") ? "release.*" : dyno
168
+ else
169
+ Socket.gethostname
170
+ end
171
+ end
172
+
162
173
  #######################
163
174
  ### Private methods ###
164
175
  #######################
@@ -25,7 +25,7 @@ module RorVsWild
25
25
 
26
26
  def to_h
27
27
  {
28
- hostname: Socket.gethostname,
28
+ hostname: RorVsWild.agent.hostname,
29
29
  os: RorVsWild.agent.os_description,
30
30
  cpu_user: cpu.user,
31
31
  cpu_system: cpu.system,
@@ -1,3 +1,3 @@
1
1
  module RorVsWild
2
- VERSION = "1.5.15".freeze
2
+ VERSION = "1.5.16".freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rorvswild
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.15
4
+ version: 1.5.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexis Bernard
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2022-08-17 00:00:00.000000000 Z
12
+ date: 2022-10-03 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: Performances and errors insights for rails developers.
15
15
  email: