puppetlabs / puppetlabs-puppet_agent

Module for managing Puppet-Agent
Apache License 2.0
41 stars 193 forks source link

add support for Amazon Linux 2023 agent in PE environment #716

Open vchepkov opened 2 months ago

vchepkov commented 2 months ago

With latest PE adding support for Amazon Linux 2023 agents, could you, please, add support to the module?

vchepkov commented 2 months ago

Maybe this is the only place where it needs to be fixed? it should have amazon prefix here

https://github.com/puppetlabs/puppetlabs-puppet_agent/blob/main/manifests/osfamily/redhat.pp#L41-L42

vchepkov commented 2 months ago

Also, for PE installation this description is incorrect https://github.com/puppetlabs/puppetlabs-puppet_agent/blob/main/manifests/osfamily/redhat.pp#L161

joshcooper commented 2 months ago

I think this was done already https://github.com/puppetlabs/puppetlabs-puppet_agent/pull/692? What behavior are you expecting? What is the actual behavior?

vchepkov commented 2 months ago

@joshcooper , I posted comments above PE repo starts with 'amazon' whereas module creates 'el-' prefix

joshcooper commented 2 months ago

@vchepkov you're describing the solution, not the problem. Can you provide steps to reproduce the problem and what behavior you're expecting?

Also /cc @span786

vchepkov commented 2 months ago

@joshcooper , I might not understand your question, I apologize Module generates repo file with the following content:

# head /etc/yum.repos.d/pc_repo.repo 
[pc_repo]
name=Puppet Labs puppet7 Repository
baseurl=https://puppet.example.com:8140/packages/2021.7.8/el-2023-x86_64

Since baseurl is incorrect, dnf fails:

 (/Stage[main]/Puppet_agent::Install/Package[puppet-agent]/ensure) change from '7.28.0-1.amazon2023' to '7.30.0' failed: Could not update: Execution of '/bin/yum -d 0 -e 0 -y update puppet-agent-7.30.0' returned 1:
joshcooper commented 2 months ago

@vchepkov ah thanks that makes sense. It looks like https://github.com/puppetlabs/puppetlabs-puppet_agent/commit/d5ad1568fec330c3196c97d209e3f61ee1c2dd29 fixed one place but not the other. @span786 can you take a look?

vchepkov commented 1 month ago

@joshcooper , @span786, considering that Amazon 2 march also was released, presumably that platform also needs to be fixed