diff --git a/yum/manifests/init.pp b/yum/manifests/init.pp index 8c14388..82bdc88 100644 --- a/yum/manifests/init.pp +++ b/yum/manifests/init.pp @@ -120,6 +120,11 @@ class yum::plugin::priorities { # Common prequisites for yum # +# === Global variables +# +# $yum_proxy: +# URL of HTTP proxy, for example "http://www.example.local:80/". +# class yum::common { case $::operatingsystem { @@ -133,6 +138,19 @@ class yum::common { } } + if $yum_proxy { + augeas { "yum-enable-proxy": + context => "/files/etc/yum.conf/main", + changes => "set proxy ${yum_proxy}", + tag => "bootstrap", + } + augeas { "yum-disable-fastestmirror": + context => "/files/etc/yum/pluginconf.d/fastestmirror.conf/main", + changes => "set enabled 0", + tag => "bootstrap", + } + } + }