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

Adding windows support. #438

Merged
merged 2 commits into from
Feb 25, 2016
Merged

Conversation

liamjbennett
Copy link
Contributor

This should allow the user to be able to install the sensu client on
windows platforms.

@liamjbennett
Copy link
Contributor Author

What are your general thoughts on this before I rebase?

@jlambert121
Copy link
Contributor

Quickly skimming it I didn't see anything that was a concern, sorry I haven't spent more time on it though in detail. I will try to do that still this week.

@liamjbennett
Copy link
Contributor Author

Ok, I will try and rebase this tomorrow.

hasrestart => $hasrestart,
subscribe => [ Class['sensu::package'], Class['sensu::api::config'], Class['sensu::redis::config'] ],
if $::osfamily != 'windows' {
service { 'sensu-api':
Copy link
Contributor

Choose a reason for hiding this comment

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

Windows doesn't have the various sensu services?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

As far as I know and per the documentation I believe only the client is supported on windows.

@fessyfoo
Copy link
Contributor

@liamjbennett this still issues. bump.

This should allow the user to be able to install the sensu client on
windows platforms.
@portertech
Copy link
Contributor

Would anyone care to have a go at fixing these Ruby 1.8.7 test failures?

1) sensu::plugin url defaults should contain Remote_file[https://raw.githubusercontent.com/sensu/sensu-community-plugins/master/plugins/system/check-mem.sh] with ensure => "present", path => "/etc/sensu/plugins/check-mem.sh" and checksum => "1d58b78e9785f893889458f8e9fe8627"

     Failure/Error: ) }

     Puppet::Error:

       Could not autoload puppet/type/remote_file: uninitialized constant FILE_PARAMS on node testing-worker-linux-docker-6f7dff96-3188-linux-5.prod.travis-ci.org

     # ./spec/defines/sensu_plugin_spec.rb:42

  2) sensu::plugin url setting params should contain Remote_file[https://raw.githubusercontent.com/sensu/sensu-community-plugins/master/plugins/system/check-mem.sh] with ensure => "present", path => "/var/sensu/plugins/check-mem.sh" and checksum => "1d58b78e9785f893889458f8e9fe8627"

     Failure/Error: ) }

     Puppet::Error:

       Could not autoload puppet/type/remote_file: uninitialized constant FILE_PARAMS on node testing-worker-linux-docker-6f7dff96-3188-linux-5.prod.travis-ci.org

     # ./spec/defines/sensu_plugin_spec.rb:57

@liamjbennett
Copy link
Contributor Author

This is a problem with the upstream remote_file module. I have raised an issue for that here: lwf/puppet-remote_file#24

I have also attempted to monkey patch but thus been unsuccessful.

I would still prefer to use the remote_file module for this rather than archive because archive requires the faraday gem and that's just a pain to deal with.

@liamjbennett
Copy link
Contributor Author

As per that issue it looks like 1.8.7 will not be supported so I need to look for an alternative if we are to continue to support 1.8.7 here.

I guess I could just switch back to the wget module and add a note the the README. Does that sound ok @portertech?

@portertech
Copy link
Contributor

@liamjbennett it would seem that any alternative w/ 1.8 support is ideal to get this in 👍

@portertech
Copy link
Contributor

@jlambert121 do we care about 1.8 anymore?

@jlambert121
Copy link
Contributor

@portertech yeah, unfortunately we care about 1.8 support since puppet 3.x still being used on RHEL6 machines is 1.8-based. Puppet 4 goes to an embedded ruby similar to sensu, but puppet 4 isn't widely deployed at this point.

@liamjbennett
Copy link
Contributor Author

I have been recently informed that the latest version of puppet-archive doesn't require the faraday gem any more and to my knowledge still has 1.8.x support. I will try and move forward with that and see how far I get

@portertech
Copy link
Contributor

@liamjbennett awesome 👍 thanks.

@liamjbennett
Copy link
Contributor Author

Just an update, I haven't had time to get back to this yet but in the mean time remote_file has been updated to support 1.8 so maybe I will go back and test this again.

We want to use remote_file because wget support on windows isn't great
and remote_file is ruby so supports multiple platforms better.
@liamjbennett
Copy link
Contributor Author

Ok @portertech the upstream remote_file dependency seems to have fixed the previous 1.8 issue and this is now working :)

@fessyfoo
Copy link
Contributor

@portertech bump.

@jlambert121
Copy link
Contributor

Thanks to everyone who has worked on this!

jlambert121 added a commit that referenced this pull request Feb 25, 2016
@jlambert121 jlambert121 merged commit cf636de into sensu:master Feb 25, 2016
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.

5 participants