Class: ElasticAPM::Metadata::SystemInfo Private
- Inherits:
-
Object
- Object
- ElasticAPM::Metadata::SystemInfo
- Defined in:
- lib/elastic_apm/metadata/system_info.rb,
lib/elastic_apm/metadata/system_info/container_info.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Defined Under Namespace
Classes: ContainerInfo
Instance Attribute Summary collapse
- #architecture ⇒ Object readonly private
- #container ⇒ Object readonly private
- #hostname ⇒ Object readonly private
- #kupernetes ⇒ Object readonly private
- #platform ⇒ Object readonly private
Instance Method Summary collapse
-
#initialize(config) ⇒ SystemInfo
constructor
private
A new instance of SystemInfo.
Constructor Details
#initialize(config) ⇒ SystemInfo
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of SystemInfo.
7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 7 def initialize(config) @config = config @hostname = @config.hostname || `hostname`.chomp @architecture = gem_platform.cpu @platform = gem_platform.os container_info = ContainerInfo.read! @container = container_info.container @kupernetes = container_info.kupernetes end |
Instance Attribute Details
#architecture ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 19 def architecture @architecture end |
#container ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 19 def container @container end |
#hostname ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 19 def hostname @hostname end |
#kupernetes ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 19 def kupernetes @kupernetes end |
#platform ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/elastic_apm/metadata/system_info.rb', line 19 def platform @platform end |