-
Notifications
You must be signed in to change notification settings - Fork 143
Puppet 8 changes #1285
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 6.0.0
Are you sure you want to change the base?
Puppet 8 changes #1285
Conversation
drop deprecated function validate_legacy use variables for cert content general format tidying fix indexer_cluster_cn
Hello @pearsondavid Thanks for your contribution! I see that the changes to the use of Puppet facts are good; we still need to test them, but the work done is greatly appreciated. Regarding some changes, I have some questions and corrections:
Also, please sign the commits you make. I'll be reviewing the code as I test it. These changes will be included in the 5.0.0 release we're working on. As soon as we have the release branches ready, I'll ask you to commit these changes to that branch. Thank you very much in advance, and I appreciate the work you've done again. |
not sure where you are seeing |
@@ -331,7 +325,7 @@ | |||
}, | |||
'cve-debian-8-oval.xml' => { | |||
'type' => 'oval', | |||
} | |||
}, | |||
} | |||
} | |||
/^(wheezy|stretch|buster|bullseye|bookworm|sid|precise|trusty|vivid|wily|xenial|bionic|focal|groovy|jammy)$/: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add noble
here?
Can we get a merge on this? puppet 7 is EOL. |
The class is not removed but heavily reformated. The diff is simply to large for the Github UI to render it per default.
Same problem here, we moved to puppet 8 prior to rolling out wazuh and are now stuck in the deployment process because of the lacking puppet 8 support. Any time estimate on the merging process would be much appreciated. |
# validate_bool( | ||
# $ossec_active_response, $ossec_rootcheck, | ||
# $selinux, | ||
# ) | ||
# This allows arrays of integers, sadly | ||
# (commented due to stdlib version requirement) | ||
validate_legacy(String, 'validate_string', $agent_package_name) | ||
validate_legacy(String, 'validate_string', $agent_service_name) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question: are the package/service names now validated at all?
it seems like a drop of the deprecated function with no current replacement?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please update the PR to set types on the variables. This should will move the validation to the module definition.
String $agent_package_name = $wazuh::params_agent::agent_package_name,
'ESTABLISHED'], | ||
'ESTABLISHED'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
chore: this removal of the indentation seems wrong, IMHO it was correct before
@@ -4,7 +4,6 @@ | |||
class wazuh::agent ( | |||
|
|||
# Versioning and package names | |||
|
|||
$agent_package_version = $wazuh::params_agent::agent_package_version, | |||
$agent_package_revision = $wazuh::params_agent::agent_package_revision, | |||
$agent_package_name = $wazuh::params_agent::agent_package_name, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$agent_package_name = $wazuh::params_agent::agent_package_name, | |
String $agent_package_name = $wazuh::params_agent::agent_package_name, |
file { "${dashboard_path_certs}/dashboard.pem": | ||
ensure => file, | ||
owner => $dashboard_fileuser, | ||
group => $dashboard_filegroup, | ||
mode => '0400', | ||
source => $dashboard_cert_content, | ||
require => Package['wazuh-dashboard'], | ||
notify => Service['wazuh-dashboard'], | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using the parameter name content
in the variable name that is passed to the source
parameter is confusing, keywords for use in a given resource should either align or be avoided - e.g. swap to $dashboard_cert_source
drop deprecated function validate_legacy
use variables for cert content
general format tidying
fix indexer_cluster_cn
re-opening, this was closed when master branch was re-named to main.
Any feedback would be welcome, rather than being ignored.