史蒂夫和斯凯 发表于 2018-8-2 08:30:02

puppet 详细使用(2)module模块配置ubuntu local repository-SystemAdmin笔记

  1).get puppet module to install apt-cacher-ng
puppet module install markhellewell-aptcacherng
  then,edit nodes.pp and put the ‘aptcacherng’>class {'aptcacherng':}  2).apply to all clients
  create a manifest file including these codes as below on puppet master which will share the configuration on all others machines,then these machines will use the local repository as proxy to apt-get packages.
class localrepo {   file { '/etc/apt/apt.conf':   owner => root, group => root, mode => 0644,  
content => 'Acquire::http { Proxy "http://192.168.56.101:3142"; }';
  
}
  
}
  puppet template
页: [1]
查看完整版本: puppet 详细使用(2)module模块配置ubuntu local repository-SystemAdmin笔记