Jira (PUP-10510) sshkeys_core 2.0.0 cannot purge sshkey resources

0 views
Skip to first unread message

Romain Tartière

unread,
May 14, 2020, 3:01:03 PM5/14/20
to puppe...@googlegroups.com
Romain Tartière created an issue
 
Puppet / Bug PUP-10510
sshkeys_core 2.0.0 cannot purge sshkey resources
Issue Type: Bug Bug
Assignee: Unassigned
Created: 2020/05/14 12:00 PM
Priority: Normal Normal
Reporter: Romain Tartière

Puppet Version: 6.15.0
Puppet Server Version: 6.11.0
OS Name/Version: CentOS / Debian

After updating the sshkeys_core module to 2.0.0 in our control repo, puppet is unable to purge sshkeys. We use the following configuration to export each host SSH keys and collect them on some of our nodes:

  1. in site.pp{{ resources { 'sshkey':}}{{   purge => true,}}{{ }}}
  2. on each node ($host_aliases is an array of the names of the node){{ @@sshkey { "sshdsakey-${host_aliases[0]}":}}{{ host_aliases => $host_aliases,}}
    {{ type => 'ssh-dss',}}
    {{ key => $facts['ssh']['dsa']['key'],}}
    {{ }}}
  3. on some nodes{{ Sshkey <<| |>>}}

Downgrading to sshkeys_core 1.0.3 fix the issue.

Desired Behavior:
When a node is decomissioned, it's SSH key should be removed from the known_hosts file of the node collecting the ssh keys.

Actual Behavior:
Puppet says it removes the key, but it's not actually done. So the configuration never converge, at each run Puppet says it remove the key.

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

Josh Cooper (Jira)

unread,
May 14, 2020, 4:25:02 PM5/14/20
to puppe...@googlegroups.com
Josh Cooper updated an issue
Change By: Josh Cooper
*Puppet Version:* 6.15.0
*Puppet Server Version:* 6.11.0
*OS Name/Version:* CentOS / Debian


After updating the sshkeys_core module to 2.0.0 in our control repo, puppet is unable to purge sshkeys. We use the following configuration to export each host SSH keys and collect them on some of our nodes:

{code:puppet}
# in site.pp {{
resources { 'sshkey': }}{{   
purge => true ,
}

{code
}

{ { code:puppet } }}
# on each node ($host_aliases is an array of the names of the node)
{{
@@sshkey \ { "sshdsakey-$ \ {host_aliases[0]}": }}{{
host_aliases => $host_aliases, }}
{{ type => 'ssh-dss', }}
{{ key => $facts['ssh']['dsa']['key'],
}

{code
}

{ { code:puppet } }}
# on some nodes
{{
Sshkey <<| |>>
{code
} }

{{ Downgrading to sshkeys_core 1.0.3 fix the issue. }}

*Desired Behavior:*

When a node is decomissioned, it's SSH key should be removed from the known_hosts file of the node collecting the ssh keys.

*Actual Behavior:*

Puppet says it removes the key, but it's not actually done. So the configuration never converge, at each run Puppet says it remove the key.

Josh Cooper (Jira)

unread,
May 14, 2020, 4:27:02 PM5/14/20
to puppe...@googlegroups.com
Josh Cooper commented on Bug PUP-10510
 
Re: sshkeys_core 2.0.0 cannot purge sshkey resources

This is probably related to the composite namevar change in MODULES-7613.

Josh Cooper (Jira)

unread,
May 14, 2020, 4:30:36 PM5/14/20
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
May 19, 2020, 10:38:03 AM5/19/20
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
May 20, 2020, 3:51:03 AM5/20/20
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: PR NW - Triage 2020-05-27

Mihai Buzgau (Jira)

unread,
May 20, 2020, 3:51:03 AM5/20/20
to puppe...@googlegroups.com

Gabriel Nagy (Jira)

unread,
May 25, 2020, 2:24:03 AM5/25/20
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
May 27, 2020, 4:02:03 AM5/27/20
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2020-05-27 , NW - 2020-06-10

Mihai Buzgau (Jira)

unread,
Jun 10, 2020, 4:54:03 AM6/10/20
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2020-05-27, NW - 2020-06-10 , NW - 2020-06-24

Ciprian Badescu (Jira)

unread,
Jul 8, 2020, 9:04:53 AM7/8/20
to puppe...@googlegroups.com
Ciprian Badescu updated an issue
Change By: Ciprian Badescu
Fix Version/s: PUP 6.17.0

Martijn Goedhart (Jira)

unread,
Sep 26, 2020, 2:47:04 PM9/26/20
to puppe...@googlegroups.com
Martijn Goedhart commented on Bug PUP-10510
 
Re: sshkeys_core 2.0.0 cannot purge sshkey resources

It seems that the solution for this problem introduced unexpected behavior when trying to "add" the same key (on a next puppet run). See report: MODULES-10828

Reply all
Reply to author
Forward
0 new messages