Project

General

Profile

Bug #14888

Updated by Alexis Mousset almost 5 years ago

Hi, 

 i hope this isn't just sorry for not having a thing on my end... 

 anyway - was dealing with a system that didn't get any automatic security updates 
 why? because rudder couldn't autodetect the distro and enforced me an invalid apt config 


 <pre> 
 root@ubu-hg:/etc/apt/sources.list.d# cat rudder-apt.list  
 ### Managed by Rudder, edit with care ### 
 deb http://de.archive.ubuntu.com/ubuntu ${apt_detected_distro}       universe multiverse  
 </pre> 


 cf-promises detects this: 
 <pre> 
 group_os_distro_ubuntu                                         source=promise,inventory,attribute_name=rudder_groups 
 ubuntu                                                         inventory,attribute_name=none,source=agent,derived-from-file=/etc/os-release,hardclass 
 ubuntu_16                                                      inventory,attribute_name=none,source=agent,derived-from=sys.flavor,hardclass 
 ubuntu_16_04                                                   inventory,attribute_name=none,source=agent,derived-from-file=/etc/os-release,hardclass 
 </pre> 

 (Agent is 5.something) 

 aptPackageManagerSettings.st apparently needed patching as here: 

 <pre> 
 @commit 89178c003b2770ee12fcf7740b70c2ad4527a0d9 
 Author: root user (CLI) <root@localhost> 
 Date:     Wed May 15 10:45:00 2019 +0200 

     bugfix ubuntu detection 

 diff --git a/techniques/applications/aptPackageManagerSettings/3.1/aptPackageManagerSettings.st b/techniques/applications/aptPackageManagerSett 
 index a149227..1ed9e73 100644 
 --- a/techniques/applications/aptPackageManagerSettings/3.1/aptPackageManagerSettings.st 
 +++ b/techniques/applications/aptPackageManagerSettings/3.1/aptPackageManagerSettings.st 
 @@ -88,7 +88,7 @@ bundle agent check_apt_settings 
      ubuntu_willy|ubuntu_15_10:: 
        "apt_detected_distro" string => "willy"; 
 
 -      ubuntu_xenial|ubuntu_16_4:: 
 +      ubuntu_xenial|ubuntu_16_4|ubuntu_16_04:: 
        "apt_detected_distro" string => "xenial"; 
 
      ubuntu_yakkety|ubuntu_16_10:: 
 </pre>

Back