Jira (PUP-11589) inifile: section-only definitoon breaks idempotency

2 views
Skip to first unread message

Takashi Kajinami (Jira)

unread,
Jul 10, 2022, 9:34:02 AM7/10/22
to puppe...@googlegroups.com
Takashi Kajinami created an issue
 
Puppet / Bug PUP-11589
inifile: section-only definitoon breaks idempotency
Issue Type: Bug Bug
Assignee: Unassigned
Components: Modules
Created: 2022/07/10 6:33 AM
Priority: Normal Normal
Reporter: Takashi Kajinami

Puppet Version: 7.16.0
Puppet Server Version: N/A
OS Name/Version: CentOS Stream 9

 

When a manifests include the ini_settings resource to mange only a config section, applying the manifests detect change in every run,

 

[vagrant@localhost ~]$ cat sectiononly.pp 
$testpath = '/home/vagrant/foo.ini'file { $testpath:
  ensure => present
}ini_setting { 'test':
  ensure  => present,
  section => 'test',
  path    => $testpath,
}File <||> -> Ini_setting <||>
[vagrant@localhost ~]$ puppet apply sectiononly.pp   --modulepath /usr/share/openstack-puppet/modules/
Notice: Compiled catalog for localhost.localdomain in environment production in 0.02 seconds
Notice: /Stage[main]/Main/File[/home/vagrant/foo.ini]/ensure: created
Notice: /Stage[main]/Main/Ini_setting[test]/ensure: created
Notice: Applied catalog in 0.01 seconds
[vagrant@localhost ~]$ cat foo.ini 
[test]
[vagrant@localhost ~]$ puppet apply sectiononly.pp   --modulepath /usr/share/openstack-puppet/modules/
Notice: Compiled catalog for localhost.localdomain in environment production in 0.02 seconds
Notice: /Stage[main]/Main/Ini_setting[test]/ensure: created
Notice: Applied catalog in 0.02 seconds
[vagrant@localhost ~]$ cat foo.ini 
[test]
[vagrant@localhost ~]$ puppet apply sectiononly.pp   --modulepath /usr/share/openstack-puppet/modules/
Notice: Compiled catalog for localhost.localdomain in environment production in 0.02 seconds
Notice: /Stage[main]/Main/Ini_setting[test]/ensure: created
Notice: Applied catalog in 0.02 seconds
[vagrant@localhost ~]$ 

 

 

This problem was initially found with puppetlabs-inifile 5.3.1 .

 

Desired Behavior:

The resource should not break idempotency

Actual Behavior:

The resource breaks idempotency

 

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v8.20.2#820002-sha1:829506d)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages