Module: Diffend::LocalContext::Host
- Defined in:
- lib/diffend/local_context/host.rb
Overview
Module responsible for building host information from local context
Class Method Summary collapse
-
.call ⇒ Hash
Build host information.
Class Method Details
.call ⇒ Hash
Build host information
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/diffend/local_context/host.rb', line 14 def call uname = Etc.uname { 'command' => command, 'ips' => ips, 'name' => uname[:nodename], 'system' => { 'machine' => uname[:machine], 'name' => uname[:sysname], 'release' => uname[:release], 'version' => uname[:version] }, 'tags' => , 'user' => Etc.getpwuid(Process.uid).name, 'pid' => Process.pid }.freeze end |