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

use gem.cmd instead of gem.bat #616

Merged
merged 1 commit into from
Apr 18, 2017
Merged

use gem.cmd instead of gem.bat #616

merged 1 commit into from
Apr 18, 2017

Conversation

andyroyle
Copy link
Contributor

yet more fun and games from the 0.27 update for windows

I've yet to find exactly out why using gem.bat fails but using gem.cmd, but it's something to do with the gems environment.

It's worth noting that gem.cmd seems to have been added in 0.27, but it's not clear if it's supposed to replace gem.bat or not

@cdenneen
Copy link
Contributor

@andyroyle what failure were you seeing?
First run as noted in #629 this test won't pass because package isn't installed.
After that it should work using the gem.bat just fine. #632 fixes that issue and I'm guessing the reason your original run was failing.

@jpuskar
Copy link

jpuskar commented Apr 6, 2017

👍 that .bat fails, .cmd works.
0.28.4.1, fresh install

@cdenneen
Copy link
Contributor

@jpuskar can you rebase from current master?
@hprins @cwjohnston think this needs to be fixed or the gem.bat needs to be fixed because it appears to be using wrong Ruby/Gem (not embedded)
Right now the sensu_gem scripts get installed under puppet embedded bin... using the cmd fixes it...

@jpuskar
Copy link

jpuskar commented Apr 10, 2017

@andyroyle, see @cdenneen's rebase request.

@andyroyle
Copy link
Contributor Author

I've rebased, but not had a chance to test the latest head of master to see if the issue has been resolved

@cdenneen
Copy link
Contributor

I tested this change and it seems to fix the issue of where plugins get installed.

@cwjohnston
Copy link
Contributor

Aside from incompatibility with Sensu versions < 0.27., this change seems okay to me

In my manual testing (without Puppet involved) of latest Sensu 0.29 package, both \opt\sensu\embedded\bin\gem.cmd and \opt\sensu\embedded\bin\gem.bat successfully install gems into the Sensu embedded Ruby. I am not able to explain why this isn't the case when the .bat file is used by Puppet.

@cdenneen
Copy link
Contributor

puppet-agent AIO ships with similar vendored ruby just like sensu
When run via puppet it uses the puppet vendored ruby and places the gems in Puppet rather than embedded.

@cdenneen
Copy link
Contributor

@cwjohnston So there is a puppet bug open on this:
https://tickets.puppetlabs.com/browse/PUP-6134
If we use the cmd if fixes issues for > 0.27 so maybe that is acceptable at this point since 0.29 is released?
cc @hprins

@jpuskar
Copy link

jpuskar commented Apr 12, 2017 via email

@cdenneen
Copy link
Contributor

@jpuskar yeah they would just install in the wrong directory too :)

@cdenneen
Copy link
Contributor

#636 hopefully should fix the issue and allow for < 0.27 versions
@cwjohnston @andyroyle @hprins

@cwjohnston cwjohnston merged commit 3e15abe into sensu:master Apr 18, 2017
@andyroyle andyroyle deleted the sensu-gem-fix branch May 2, 2017 15:14
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.

4 participants