Getting Yum errors for nginx install

95 views
Skip to first unread message

mike r

unread,
Jan 27, 2016, 8:12:16 AM1/27/16
to Puppet Users
running nginx module on centos 6.6 (only getting this error for centos 66, also tried centos 7 and ubuntu 12,14 and no errors,)

wondering if anyone has seen this output.

Error: Execution of '/usr/bin/yum -d 0 -e 0 -y install nginx' returned 1: Error: Nothing to do
Error: /Stage[main]/Nginx::Install/Package[nginx]/ensure: change from purged to present failed: Execution of '/usr/bin/yum -d 0 -e 0 -y install nginx' returned 1: Error: Nothing to do



my install.pp looks like this,


 # check node agent version
$fqdn = $::fqdn

if $puppet_agent_version < '3.8' {
  fail("---- Node ${fqdn} has a Puppet agent version: ${puppet_agent_version} which is not compatible with this module. Need to have minimum Puppet agent 3.8 -----")
}


package { 'nginx':
  name   => $package_name,
  ensure => present,
}


file { [$nginx_dirs]:
  ensure  => directory,
  mode    => '0644',
  owner   => 'root',
  group   => 'root',
  require => Package['nginx'],
}


user { 'nginx_user':
  name             => $user,
  ensure           => 'present',
  comment          => "${user}",
  home             => '/var/www',
  password         => '*',
  password_max_age => '99999',
  password_min_age => '0',
  shell            => '/usr/sbin/nologin',
  require          => Package['nginx'],
}


}



mike r

unread,
Jan 27, 2016, 8:31:34 AM1/27/16
to Puppet Users
looks like issues w  my repos.d, had to install 

sudo yum install epel-release
Reply all
Reply to author
Forward
0 new messages