-
Notifications
You must be signed in to change notification settings - Fork 279
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
Package install is never up to date #621
Comments
Hmm I don't recall seeing this with ubuntu I think you need to configure both of these attributes because epel versioning as of centos7: https://github.com/sensu/sensu-chef/blob/v5.4.0/attributes/default.rb#L20-L21 Let me know if that works if not I can try to dig into it a bit. |
Thanks for the reply. This is actually to do with the epoch value not the platform value. what I'm needing or at least running into is its wanting the affix which is what epoch is. At least thats what I can see. |
I will try to look into this sometime this week but I am on-call so I can't guarantee I will find much time until the weekend. Can you verify if the debian based distros also exhibit this issue? |
Apologies got a little busy with some things at work. Yes I will most likely have some time in the morning to delve a little into this. On a side note speaking of denian looks like this has been addressed to #517 Which actually supports what I noticed when adding epoch. I will need to test tho if not including epoch will suffice a package already being up to date in debian. |
@xxwassyxx just checking if you had time to get around to this |
Expected Behavior
Kitchen converge on subsequent runs should have no resources changed
Current Behavior
On subsequent runs the package for sensu keeps getting installed, as a result it triggers a service restart.
Possible Solution
Basically the issue appears to be in the epoch version. if I do a yum info of sensu I get
Name : sensu Arch : x86_64 Epoch : 1 Version : 1.5.0 Release : 1.el7 Size : 82 M Repo : installed From repo : sensu Summary : A monitoring framework that aims to be simple, malleable, and scalable. URL : https://sensu.io License : MIT Description : A monitoring framework that aims to be simple, malleable, and scalable.
and if I in my cookbook a simple
package 'sensu' do version '1:1.5.0-1.el7' end
Everything works as expected. But using the attribute
default["sensu"]["version"] = '1:1.5.0-1'
I get an error
FATAL: ArgumentError: Malformed version number string 1:1.5.0
if I use
default["sensu"]["version"] = '1.5.0-1'
The package just gets installed at every run of chef and triggers a restart of the service
Looks like were doing a lazy against the helper to join the version together in the helper. so I wonder if there is either an issue in sending the ':' to the helper, which seems fine and just does a join anyway or something else?
Steps to Reproduce (for bugs)
3.kitchen converge first time things look good
4.kitchen converge a second time and package is set to install again, triggering a restart of he service
Context
Right now im trying to get he cookbook working before putting this up into the environment
Your Environment
The text was updated successfully, but these errors were encountered: