Puppet

Puppet - 確保存在 cent base repo

  • May 11, 2013

使用 puppet manifest,你如何確保官方的 cent ‘base’ repo 存在。

添加內部 cent 回購的範例

http://seriousbirder.com/blogs/how-to-create-a-puppet-yum-repo-module/

debian 系統範例

https://forge.puppetlabs.com/puppetlabs/apt

如果您查看 /etc/yum.repos.d/CentOS-Base.repo,您​​會看到條目清晰地映射到您提供的連結中的範例:http: //seriousbirder.com/blogs/how-to-創建-a-puppet-yum-repo-module/

例如:

     yumrepo {
    "CentOS6-Base":
       descr          => "CentOS-\$releasever - Base",
       mirrorlist     => "http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os",
       gpgcheck       => "1",
       gpgkey         => "file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6",
       enabled        => "1";
     } ### End yumrepo::

引用自:https://serverfault.com/questions/506880