source: ocsinventory-agent/trunk/fuentes/lib/Ocsinventory/Agent/Backend/OS/Linux/Distro/LSB.pm @ 468

Last change on this file since 468 was 468, checked in by mabarracus, 4 years ago

Copyt trusty code

File size: 412 bytes
Line 
1package Ocsinventory::Agent::Backend::OS::Linux::Distro::LSB;
2
3sub check {can_run("lsb_release")}
4
5sub run {
6  my $params = shift;
7  my $common = $params->{common};
8
9  my $release;
10  foreach (`lsb_release -d`) {
11    $release = $1 if /Description:\s+(.+)/;
12  }
13  my $OSComment;
14  chomp($OSComment =`uname -v`);
15
16  $common->setHardware({ 
17      OSNAME => $release,
18      OSCOMMENTS => "$OSComment"
19    });
20}
21
22
23
241;
Note: See TracBrowser for help on using the repository browser.