Skip to content
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

Fix rpm key handling + changing default values depending on zabbix version #399

Merged
merged 5 commits into from
Jun 5, 2017

Conversation

bastelfreak
Copy link
Member

These are multiple bugs that I found while doing acceptance testing. The implementation is described in the individual commit messages. This fixes #398 and #397 and is based on the work from #396 and #382

zabbix introduced one new key for 3.2 releases, but that one is
currently only used in the main repo. Noticed this by doing acceptance tests
\o/
This is needed to allow upgrades after a changed zabbix_version parameter.
In general this is a safe option, since zabbix only pushes patch releases
into the same repository.
@@ -68,7 +68,7 @@
}

# Zabbix overall params. Is used by all components.
$zabbix_package_state = 'present'
$zabbix_package_state = 'latest'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is a good idea. Nothing will automatically bump zabbix_version when updated packages get installed.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is for the use case that somebody runs zabbix 3.0 or 2.4 and wants to update to 3.2.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, you should never do this.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, but this would then just happen whilst zabbix_version would still say 2.4 or whatever. Incompatible configuration would then be applied. I think you need a separate parameter for package_version.

@bastelfreak bastelfreak force-pushed the rpm_keys branch 3 times, most recently from 637b507 to e17872e Compare June 5, 2017 17:11
We now do proper acceptance tests for zabbix-agent. We first install the
oldest, but still supported, version 2.4. After that we upgrade it to
the newest version, 3.2.
this is a really really nasty bug. A few of the default values we
provide depend on the zabbix version. Their default value is different
based on the zabbix version. We deal with this in the params.pp, but
that codeblock is always ignored if you provide a zabbix version by
yourself. This is now fixed and proven to work by acceptance tests.
Copy link
Member

@dhollinger dhollinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@dhollinger dhollinger merged commit 3e38b3f into voxpupuli:master Jun 5, 2017
@bastelfreak bastelfreak deleted the rpm_keys branch June 5, 2017 18:05
@alexjfisher alexjfisher changed the title Fix rpm key handling + chaning default values depending on zabbix version Fix rpm key handling + changing default values depending on zabbix version Jun 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fails to upgrade zabbix-agent if zabbix_version is changed
4 participants