Class: Specinfra::Helper::DetectOs
- Inherits:
-
Object
- Object
- Specinfra::Helper::DetectOs
show all
- Defined in:
- lib/specinfra/helper/detect_os.rb
Direct Known Subclasses
Aix, Alpine, Arch, Coreos, Darwin, Debian, Esxi, Freebsd, Gentoo, Nixos, Openbsd, Plamo, Redhat, Solaris, Suse
Defined Under Namespace
Classes: Aix, Alpine, Arch, Coreos, Darwin, Debian, Esxi, Freebsd, Gentoo, Nixos, Openbsd, Plamo, Redhat, Solaris, Suse
Class Method Summary
collapse
Instance Method Summary
collapse
Constructor Details
#initialize(backend) ⇒ DetectOs
8
9
10
|
# File 'lib/specinfra/helper/detect_os.rb', line 8
def initialize(backend)
@backend = backend
end
|
Class Method Details
.detect ⇒ Object
4
5
6
|
# File 'lib/specinfra/helper/detect_os.rb', line 4
def self.detect
self.new(Specinfra.backend).detect
end
|
Instance Method Details
#detect ⇒ Object
16
17
18
|
# File 'lib/specinfra/helper/detect_os.rb', line 16
def detect
raise NotImplementedError
end
|
#run_command(cmd) ⇒ Object
12
13
14
|
# File 'lib/specinfra/helper/detect_os.rb', line 12
def run_command(cmd)
@backend.run_command(cmd)
end
|