{"action":"created","issue":{"url":"https://api.github.com/repos/sensu/sensu-puppet/issues/908","repository_url":"https://api.github.com/repos/sensu/sensu-puppet","labels_url":"https://api.github.com/repos/sensu/sensu-puppet/issues/908/labels{/name}","comments_url":"https://api.github.com/repos/sensu/sensu-puppet/issues/908/comments","events_url":"https://api.github.com/repos/sensu/sensu-puppet/issues/908/events","html_url":"https://github.com/sensu/sensu-puppet/issues/908","id":327495178,"node_id":"MDU6SXNzdWUzMjc0OTUxNzg=","number":908,"title":"Allow gem_install_options on sensu_gem plugins to work on Windows","user":{"login":"ghoneycutt","id":313891,"node_id":"MDQ6VXNlcjMxMzg5MQ==","avatar_url":"https://avatars3.githubusercontent.com/u/313891?v=4","gravatar_id":"","url":"https://api.github.com/users/ghoneycutt","html_url":"https://github.com/ghoneycutt","followers_url":"https://api.github.com/users/ghoneycutt/followers","following_url":"https://api.github.com/users/ghoneycutt/following{/other_user}","gists_url":"https://api.github.com/users/ghoneycutt/gists{/gist_id}","starred_url":"https://api.github.com/users/ghoneycutt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ghoneycutt/subscriptions","organizations_url":"https://api.github.com/users/ghoneycutt/orgs","repos_url":"https://api.github.com/users/ghoneycutt/repos","events_url":"https://api.github.com/users/ghoneycutt/events{/privacy}","received_events_url":"https://api.github.com/users/ghoneycutt/received_events","type":"User","site_admin":false},"labels":[{"id":804773904,"node_id":"MDU6TGFiZWw4MDQ3NzM5MDQ=","url":"https://api.github.com/repos/sensu/sensu-puppet/labels/V2","name":"V2","color":"b5ed95","default":false},{"id":3587095,"node_id":"MDU6TGFiZWwzNTg3MDk1","url":"https://api.github.com/repos/sensu/sensu-puppet/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"open","locked":false,"assignee":{"login":"treydock","id":739622,"node_id":"MDQ6VXNlcjczOTYyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/739622?v=4","gravatar_id":"","url":"https://api.github.com/users/treydock","html_url":"https://github.com/treydock","followers_url":"https://api.github.com/users/treydock/followers","following_url":"https://api.github.com/users/treydock/following{/other_user}","gists_url":"https://api.github.com/users/treydock/gists{/gist_id}","starred_url":"https://api.github.com/users/treydock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/treydock/subscriptions","organizations_url":"https://api.github.com/users/treydock/orgs","repos_url":"https://api.github.com/users/treydock/repos","events_url":"https://api.github.com/users/treydock/events{/privacy}","received_events_url":"https://api.github.com/users/treydock/received_events","type":"User","site_admin":false},"assignees":[{"login":"treydock","id":739622,"node_id":"MDQ6VXNlcjczOTYyMg==","avatar_url":"https://avatars1.githubusercontent.com/u/739622?v=4","gravatar_id":"","url":"https://api.github.com/users/treydock","html_url":"https://github.com/treydock","followers_url":"https://api.github.com/users/treydock/followers","following_url":"https://api.github.com/users/treydock/following{/other_user}","gists_url":"https://api.github.com/users/treydock/gists{/gist_id}","starred_url":"https://api.github.com/users/treydock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/treydock/subscriptions","organizations_url":"https://api.github.com/users/treydock/orgs","repos_url":"https://api.github.com/users/treydock/repos","events_url":"https://api.github.com/users/treydock/events{/privacy}","received_events_url":"https://api.github.com/users/treydock/received_events","type":"User","site_admin":false}],"milestone":null,"comments":24,"created_at":"2018-05-29T21:31:58Z","updated_at":"2018-06-19T19:32:13Z","closed_at":null,"author_association":"MEMBER","body":"## Description of problem\r\n\r\ngem_install_options were added in v2.53.0 though do not work for windows. See PR #878"},"comment":{"url":"https://api.github.com/repos/sensu/sensu-puppet/issues/comments/398518150","html_url":"https://github.com/sensu/sensu-puppet/issues/908#issuecomment-398518150","issue_url":"https://api.github.com/repos/sensu/sensu-puppet/issues/908","id":398518150,"node_id":"MDEyOklzc3VlQ29tbWVudDM5ODUxODE1MA==","user":{"login":"cdenneen","id":720097,"node_id":"MDQ6VXNlcjcyMDA5Nw==","avatar_url":"https://avatars0.githubusercontent.com/u/720097?v=4","gravatar_id":"","url":"https://api.github.com/users/cdenneen","html_url":"https://github.com/cdenneen","followers_url":"https://api.github.com/users/cdenneen/followers","following_url":"https://api.github.com/users/cdenneen/following{/other_user}","gists_url":"https://api.github.com/users/cdenneen/gists{/gist_id}","starred_url":"https://api.github.com/users/cdenneen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cdenneen/subscriptions","organizations_url":"https://api.github.com/users/cdenneen/orgs","repos_url":"https://api.github.com/users/cdenneen/repos","events_url":"https://api.github.com/users/cdenneen/events{/privacy}","received_events_url":"https://api.github.com/users/cdenneen/received_events","type":"User","site_admin":false},"created_at":"2018-06-19T19:32:12Z","updated_at":"2018-06-19T19:32:12Z","author_association":"CONTRIBUTOR","body":"@treydock got the following now:\r\n\r\n```\r\n  $sensu_plugin_defaults = {\r\n    type                => 'package',\r\n    pkg_provider        => 'sensu_gem',\r\n    pkg_version         => 'installed',\r\n    gem_install_options => $facts['os']['family'] ? {\r\n      'RedHat' => [{'--source' => 'https://artifactory.domain.com/api/rubygems/rubygems'}, '--','--use-system-libraries'],\r\n      'Debian' => [{'--source' => 'https://artifactory.domain.com/api/rubygems/rubygems'}, '--','--use-system-libraries'],\r\n      default  => undef,\r\n    },\r\n    require             => $facts['os']['family'] ? {\r\n      'RedHat' => [Package['sensu'],Package['libxml2-devel'],Package['libxslt-devel']],\r\n      default  => Package['sensu'],\r\n    }\r\n  }\r\n  $sensu_plugins.each |String $plugins| {\r\n    sensu::plugin { $plugins :\r\n      * => $sensu_plugin_defaults\r\n    }\r\n  }\r\n```\r\n\r\nbut it seems like it's breaking normal package installs or something:\r\n\r\n```\r\n       \tError: Execution of '/opt/sensu/embedded/bin/gem install --no-rdoc --no-ri sensu-plugins-aws --source=https://artifactory.domain.com/api/rubygems/rubygems -- --use-system-libraries' returned 1: Building native extensions with: '--use-system-libraries'\r\n       \tThis could take a while...\r\n       \tERROR:  Error installing sensu-plugins-aws:\r\n       \t\tERROR: Failed to build gem native extension.\r\n       \t\r\n       \t    current directory: /opt/sensu/embedded/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.3/ext/nokogiri\r\n       \t/opt/sensu/embedded/bin/ruby -r ./siteconf20180619-15885-6sqauj.rb extconf.rb --use-system-libraries\r\n       \tchecking if the C compiler accepts ... yes\r\n       \tBuilding nokogiri using system libraries.\r\n       \tpkg-config could not be used to find libxml-2.0\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tpkg-config could not be used to find libxslt\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tpkg-config could not be used to find libexslt\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tERROR: cannot discover where libxml2 is located on your system. please make sure `pkg-config` is installed.\r\n       \t*** extconf.rb failed ***\r\n       \tCould not create Makefile due to some reason, probably lack of necessary\r\n       \tlibraries and/or headers.  Check the mkmf.log file for more details.  You may\r\n       \tneed configuration options.\r\n       \t\r\n       \tProvided configuration options:\r\n       \t\t--with-opt-dir\r\n       \t\t--with-opt-include\r\n       \t\t--without-opt-include=${opt-dir}/include\r\n       \t\t--with-opt-lib\r\n       \t\t--without-opt-lib=${opt-dir}/lib\r\n       \t\t--with-make-prog\r\n       \t\t--without-make-prog\r\n       \t\t--srcdir=.\r\n       \t\t--curdir\r\n       \t\t--ruby=/opt/sensu/embedded/bin/$(RUBY_BASE_NAME)\r\n       \t\t--help\r\n       \t\t--clean\r\n       \t\t--use-system-libraries\r\n       \t\t--with-zlib-dir\r\n       \t\t--without-zlib-dir\r\n       \t\t--with-zlib-include\r\n       \t\t--without-zlib-include=${zlib-dir}/include\r\n       \t\t--with-zlib-lib\r\n       \t\t--without-zlib-lib=${zlib-dir}/lib\r\n       \t\t--with-xml2-dir\r\n       \t\t--without-xml2-dir\r\n       \t\t--with-xml2-include\r\n       \t\t--without-xml2-include=${xml2-dir}/include\r\n       \t\t--with-xml2-lib\r\n       \t\t--without-xml2-lib=${xml2-dir}/lib\r\n       \t\t--with-libxml-2.0-config\r\n       \t\t--without-libxml-2.0-config\r\n       \t\t--with-pkg-config\r\n       \t\t--without-pkg-config\r\n       \t\t--with-xslt-dir\r\n       \t\t--without-xslt-dir\r\n       \t\t--with-xslt-include\r\n       \t\t--without-xslt-include=${xslt-dir}/include\r\n       \t\t--with-xslt-lib\r\n       \t\t--without-xslt-lib=${xslt-dir}/lib\r\n       \t\t--with-libxslt-config\r\n       \t\t--without-libxslt-config\r\n       \t\t--with-exslt-dir\r\n       \t\t--without-exslt-dir\r\n       \t\t--with-exslt-include\r\n       \t\t--without-exslt-include=${exslt-dir}/include\r\n       \t\t--with-exslt-lib\r\n       \t\t--without-exslt-lib=${exslt-dir}/lib\r\n       \t\t--with-libexslt-config\r\n       \t\t--without-libexslt-config\r\n       \t\r\n       \tTo see why this extension failed to compile, please check the mkmf.log which can be found here:\r\n       \t\r\n       \t  /opt/sensu/embedded/lib/ruby/gems/2.4.0/extensions/x86_64-linux/2.4.0/nokogiri-1.8.3/mkmf.log\r\n       \t\r\n       \textconf failed, exit code 1\r\n       \t\r\n       \tGem files will remain installed in /opt/sensu/embedded/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.3 for inspection.\r\n       \tResults logged to /opt/sensu/embedded/lib/ruby/gems/2.4.0/extensions/x86_64-linux/2.4.0/nokogiri-1.8.3/gem_make.out\r\n       \tError: /Stage[main]/Profile_base::Sensu/Sensu::Plugin[sensu-plugins-aws]/Package[sensu-plugins-aws]/ensure: change from absent to present failed: Execution of '/opt/sensu/embedded/bin/gem install --no-rdoc --no-ri sensu-plugins-aws --source=https://artifactory.domain.com/api/rubygems/rubygems -- --use-system-libraries' returned 1: Building native extensions with: '--use-system-libraries'\r\n       \tThis could take a while...\r\n       \tERROR:  Error installing sensu-plugins-aws:\r\n       \t\tERROR: Failed to build gem native extension.\r\n       \t\r\n       \t    current directory: /opt/sensu/embedded/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.3/ext/nokogiri\r\n       \t/opt/sensu/embedded/bin/ruby -r ./siteconf20180619-15885-6sqauj.rb extconf.rb --use-system-libraries\r\n       \tchecking if the C compiler accepts ... yes\r\n       \tBuilding nokogiri using system libraries.\r\n       \tpkg-config could not be used to find libxml-2.0\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tpkg-config could not be used to find libxslt\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tpkg-config could not be used to find libexslt\r\n       \tPlease install either `pkg-config` or the pkg-config gem per\r\n       \t\r\n       \t    gem install pkg-config -v \"~> 1.1\"\r\n       \t\r\n       \tERROR: cannot discover where libxml2 is located on your system. please make sure `pkg-config` is installed.\r\n       \t*** extconf.rb failed ***\r\n       \tCould not create Makefile due to some reason, probably lack of necessary\r\n       \tlibraries and/or headers.  Check the mkmf.log file for more details.  You may\r\n       \tneed configuration options.\r\n       \t\r\n       \tProvided configuration options:\r\n       \t\t--with-opt-dir\r\n       \t\t--with-opt-include\r\n       \t\t--without-opt-include=${opt-dir}/include\r\n       \t\t--with-opt-lib\r\n       \t\t--without-opt-lib=${opt-dir}/lib\r\n       \t\t--with-make-prog\r\n       \t\t--without-make-prog\r\n       \t\t--srcdir=.\r\n       \t\t--curdir\r\n       \t\t--ruby=/opt/sensu/embedded/bin/$(RUBY_BASE_NAME)\r\n       \t\t--help\r\n       \t\t--clean\r\n       \t\t--use-system-libraries\r\n       \t\t--with-zlib-dir\r\n       \t\t--without-zlib-dir\r\n       \t\t--with-zlib-include\r\n       \t\t--without-zlib-include=${zlib-dir}/include\r\n       \t\t--with-zlib-lib\r\n       \t\t--without-zlib-lib=${zlib-dir}/lib\r\n       \t\t--with-xml2-dir\r\n       \t\t--without-xml2-dir\r\n       \t\t--with-xml2-include\r\n       \t\t--without-xml2-include=${xml2-dir}/include\r\n       \t\t--with-xml2-lib\r\n       \t\t--without-xml2-lib=${xml2-dir}/lib\r\n       \t\t--with-libxml-2.0-config\r\n       \t\t--without-libxml-2.0-config\r\n       \t\t--with-pkg-config\r\n       \t\t--without-pkg-config\r\n       \t\t--with-xslt-dir\r\n       \t\t--without-xslt-dir\r\n       \t\t--with-xslt-include\r\n       \t\t--without-xslt-include=${xslt-dir}/include\r\n       \t\t--with-xslt-lib\r\n       \t\t--without-xslt-lib=${xslt-dir}/lib\r\n       \t\t--with-libxslt-config\r\n       \t\t--without-libxslt-config\r\n       \t\t--with-exslt-dir\r\n       \t\t--without-exslt-dir\r\n       \t\t--with-exslt-include\r\n       \t\t--without-exslt-include=${exslt-dir}/include\r\n       \t\t--with-exslt-lib\r\n       \t\t--without-exslt-lib=${exslt-dir}/lib\r\n       \t\t--with-libexslt-config\r\n       \t\t--without-libexslt-config\r\n       \t\r\n       \tTo see why this extension failed to compile, please check the mkmf.log which can be found here:\r\n       \t\r\n       \t  /opt/sensu/embedded/lib/ruby/gems/2.4.0/extensions/x86_64-linux/2.4.0/nokogiri-1.8.3/mkmf.log\r\n       \t\r\n       \textconf failed, exit code 1\r\n       \t\r\n       \tGem files will remain installed in /opt/sensu/embedded/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.3 for inspection.\r\n       \tResults logged to /opt/sensu/embedded/lib/ruby/gems/2.4.0/extensions/x86_64-linux/2.4.0/nokogiri-1.8.3/gem_make.out\r\n```"}}
{"actor":{"display_login":"cdenneen"}}