使用puppet安装pear包
我正在尝试使用puppet安装pear包“HTTP_Request2”。目标操作系统是RHEL 7 我遇到了两个木偶模块,我相信它们应该能够做到这一点 理想情况下,我希望使用refaelfc模块,因为它似乎更适合此任务。我遇到的问题是,要在目标服务器上获得internet访问权限,您需要通过代理,我在这个模块中似乎找不到任何设置。如果没有此设置,则在尝试安装模块时,puppet将超时 使用选项2,我将以下内容添加到清单中:使用puppet安装pear包,puppet,pear,Puppet,Pear,我正在尝试使用puppet安装pear包“HTTP_Request2”。目标操作系统是RHEL 7 我遇到了两个木偶模块,我相信它们应该能够做到这一点 理想情况下,我希望使用refaelfc模块,因为它似乎更适合此任务。我遇到的问题是,要在目标服务器上获得internet访问权限,您需要通过代理,我在这个模块中似乎找不到任何设置。如果没有此设置,则在尝试安装模块时,puppet将超时 使用选项2,我将以下内容添加到清单中: include php php::pear::con
include php
php::pear::config { http_proxy: value => "http://xx.xx.xx.xx:xxxx" }
php::pear::module { 'HTTP_Request2':
repository => 'pear.phpunit.de',
alldeps => 'true',
require => Php::Pear::Config['http_proxy'],
}
执行此操作时,我得到错误信息:
Error: Execution of '/bin/yum -d 0 -e 0 -y list php-pear-HTTP_Request2' returned 1: Error: No matching Packages to list
它不应该去百胜?如何让puppet安装此pear软件包?使用example42/php模块和自定义脚本的组合使其正常工作:
include php
php::pear::config { http_proxy:
value => "http://xx.xx.xx.xx:xxxx",
}
exec { 'HTTP_Request2':
command => '/usr/bin/pear install HTTP_Request2',
unless => '/usr/bin/pear info HTTP_Request2',
require => Php::Pear::Config['http_proxy'],
}