Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-04-29 Thread Gheorghe Popescu (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Gheorghe Popescu updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Gheorghe Popescu  
 

  
 
 
 
 

 
 Implement  SemVerRange  Version Range  type support for the {{yum}} provider.Sample manifest with a range passed for a package:{code:title=|language=none|collapse=false} package { 'puppet-agent':    # this will be parsed as: >= 6.0.0 < 6.1.0  ensure => SemVerRange('~> 6.0')} package { 'puppet-agent':  ensure =>  SemVerRange( '>= 6.5' ) }package { 'puppet-agent':  ensure =>  SemVerRange( '< 6.4' ) }package { 'puppet-agent':   # this is a valid range which we can support   ensure =>  SemVerRange( ' ~ > 6. 0 || ~> 6.11 4 <=7 ' ) }{code}The {{yum}} provider does not support a version range passed in the install command, so we have to:* find out the available versions for a specific package (usually with {{yum list --showduplicates}})* install the most recent package which respects the range.We should also make sure we don't take additional actions if the range is already satisfied (i.e. puppet apply with a {{SemVerRange}} should be idempotent)Sample code on how the ensure property can be treated inside the provider:{code:title=|language=none|collapse=false}if @resource.should(:ensure).is_a?(SemanticPuppet::VersionRange)  # these should be sorted in descending order  _, *versions = `yum list -d 0 -e 1 --showduplicates #{@resource.name} | awk '{print $2}'`.split  range = @resource.should(:ensure)  available.versions.any? { |version| range.include?(version.to_stable) }end{code}Example {{yum install}} with a specific version (package name and version are joined by a dash):{noformat}yum install puppet-agent-6.0.4-1.el7{noformat} Limitations of Version Ranges: YUM provider is using RPM to compare package versions and no epoch is considered `zero`  epoch. As a consequence to this we need to specify also the epoch if we don't want the default behaviourFor example:- *>1 <2* will search in (0:1, 0:2) interval- *>1 <1:2* will search in (0:1, 1:2) interval, eligible versions will be searched in bot 0 and 1 epoch- *>1* will consider any version form epoch 0, greater that 1 and any version with epoch > 0  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 
  

Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-04-29 Thread Gheorghe Popescu (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Gheorghe Popescu updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Gheorghe Popescu  
 

  
 
 
 
 

 
 Implement Version Range type support for the {{yum}} provider.Sample manifest with a range passed for a package:  {code:title=|language=none|collapse=false}  package { 'puppet-agent':  ensure => '>= 6.5'}package { 'puppet-agent':  ensure => '< 6.4'}package { 'puppet-agent':  ensure => '>6.4 <=7'}{code}  The {{yum}} provider does not support a version range passed in the install command, so we have to:  * find out the available versions for a specific package (usually with {{yum list --showduplicates}})* install the most recent package which respects the range.We should also make sure we don't take additional actions if the range is already satisfied (i.e. puppet apply with a {{SemVerRange}} should be idempotent)Sample code on how the ensure property can be treated inside the provider:  {code:title=|language=none|collapse=false}if @resource.should(:ensure).is_a?(SemanticPuppet::VersionRange)  # these should be sorted in descending order  _, *versions = `yum list -d 0 -e 1 --showduplicates #{@resource.name} | awk '{print $2}'`.split  range = @resource.should(:ensure)  available.versions.any? { |version| range.include?(version.to_stable) }end{code}  Example {{yum install}} with a specific version (package name and version are joined by a dash):  {noformat}  yum install puppet-agent-6.0.4-1.el7{noformat}      Limitations of Version Ranges: YUM provider is using RPM to compare package versions and no epoch is considered `zero`  epoch. As a consequence to this we need to specify also the epoch if we don't want the default behaviourFor example:- *>1 <2* will search in (0:1, 0:2) interval- *>1 <1:2* will search in (0:1, 1:2) interval, eligible versions will be searched in bot 0 and 1 epoch- *>1* will consider any version form epoch 0, greater that 1 and any version with epoch > 0  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  

Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-04-27 Thread Claire Cadman (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Claire Cadman updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Claire Cadman  
 
 
Labels: 
 doc_reviewed  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.47565.1587990660030%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-04-23 Thread Gabriel Nagy (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Gabriel Nagy updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Gabriel Nagy  
 
 
Fix Version/s: 
 PUP 6.15.0  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.45243.1587643320211%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-04-01 Thread Mihai Buzgau (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Sprint: 
 NW - 2020-03-04, NW - 2020-03-17, NW - 2020-04-01 , NW - 2020-04-15  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.27209.1585727460131%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-03-18 Thread Mihai Buzgau (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Sprint: 
 NW - 2020-03-04, NW - 2020-03-17 , NW - 2020-04-01  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.15016.1584521640191%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-03-05 Thread Mihai Buzgau (Jira)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Sprint: 
 NW - 2020-03-04 , NW - 2020-03-17  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.5425.1583398440231%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-02-26 Thread Mihai Buzgau (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau assigned an issue to Dorin Pleava  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Assignee: 
 Dorin Pleava  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.267.1582708920197%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-02-19 Thread Mihai Buzgau (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Sprint: 
 PR NW  -  Triage  2020-03-04  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.31016.1582110783170%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-02-19 Thread Mihai Buzgau (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Story Points: 
 5  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.31001.1582110722580%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-02-18 Thread Mihai Buzgau (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Mihai Buzgau updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Change By: 
 Mihai Buzgau  
 
 
Component/s: 
 Types and Providers  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.346487.1582028908000.27917.1582029841648%40Atlassian.JIRA.


Jira (PUP-10298) Add SemVerRange support to yum package provider

2020-02-18 Thread Gabriel Nagy (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Gabriel Nagy created an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Puppet /  PUP-10298  
 
 
  Add SemVerRange support to yum package provider   
 

  
 
 
 
 

 
Issue Type: 
  New Feature  
 
 
Assignee: 
 Unassigned  
 
 
Created: 
 2020/02/18 4:28 AM  
 
 
Priority: 
  Normal  
 
 
Reporter: 
 Gabriel Nagy  
 

  
 
 
 
 

 
 Implement SemVerRange type support for the yum provider. Sample manifest with a range passed for a package:  
 
 
 
 
   
 
 
 
 
 package { 'puppet-agent':  
 
 
   # this will be parsed as: >= 6.0.0 < 6.1.0  
 
 
   ensure => SemVerRange('~> 6.0')  
 
 
 }  
 
 
    
 
 
 package {