Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

Ruby issue for installing "google-api-client" gem

$
0
0
Issue: Unable to install required gems (google-api-client) to use custom resource modules. we require some way to handle the ruby issue for installing "google-api-client" gem. Version details Operating System : Ubuntu 16.04 “ sudo /opt/puppetlabs/bin/puppetserver ruby –v “ jruby 1.7.26 (1.9.3p551) 2016-08-26 69763b8 on OpenJDK 64-Bit Server VM 1.8.0_91-8u91-b14- 3ubuntu1~16.04.1-b14 +jit [linux-amd64] “ puppet –V ” 4.7.0 “ puppetserver –v ” 2.6.0 Environment: The below are the steps to install/configure puppet server/agent. # Puppet -4.7 #################### # config directory location - # ~/.puppetlabs/etc/puppet # Puppet-Server (2.6) ####################### wget https://apt.puppetlabs.com/puppetlabs-release-pc1-xenial.deb sudo dpkg -i puppetlabs-release-pc1-xenial.deb sudo apt update sudo apt-get install puppetserver # master settings ################## # cat ~/.puppetlabs/etc/puppet/puppet.conf [main] certname = puppet4-server-magento.c.graphite-development.internal server = puppet4-server-magento.c.graphite-development.internal environment = production runinterval = 1h strict_variables = true autosign = ~/.puppetlabs/etc/puppet [master] reports = puppetdb storeconfigs_backend = puppetdb storeconfigs = true environment_timeout = unlimited # EOF # cat ~/.puppetlabs/etc/puppet/autosign.conf *.c.graphite-development.internal #EOF service puppetserver start # Puppet-Agent ############### wget https://apt.puppetlabs.com/puppetlabs-release-pc1-xenial.deb sudo dpkg -i puppetlabs-release-pc1-xenial.deb sudo apt update sudo apt-get -y --force-yes install puppet-agent # cat ~/.puppetlabs/etc/puppet/puppet.conf [main] certname = puppet4-agent-magento.c.graphite-development.internal server = puppet4-server-magento.c.graphite-development.internal environment = production runinterval = 1h sudo /opt/puppetlabs/bin/puppet resource service puppet ensure=running enable=true sudo /opt/puppetlabs/bin/puppet agent –test ############### # We need to install the below gem in puppet server and agent ############### sudo -i puppetserver gem install inifile googleauth google-api-client --no-ri --no-rdoc Points to be considered: 1. Puppet will run independent of the ruby version we are using as it will have a inbuilt ruby. Link : https://docs.puppet.com/guides/platforms.html under section “Ruby versions” 2. The custom google resource modules that we are using will only work on ruby version 2.x as the gem ‘google-api-client’ requires the same.(as mentioned in custom resource module readme document) 3. We will not install gems in the puppet-agent as it will only take the gems from the puppetserver. Link: https://docs.puppet.com/puppetserver/latest/gems.html under section “Installing And Removing Gem”

Viewing all articles
Browse latest Browse all 6104

Trending Articles