码迷,mamicode.com
首页 > 系统相关 > 详细

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

时间:2016-03-22 06:34:55      阅读:357      评论:0      收藏:0      [点我收藏+]

标签:puppet module

1).get puppet module to install apt-cacher-ng

puppet module install markhellewell-aptcacherng

then,edit nodes.pp and put the ‘aptcacherng’ class into the repo node

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


本文出自 “SystemAdmin成长记” 博客,请务必保留此出处http://christhai.blog.51cto.com/1584747/1753662

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

标签:puppet module

原文地址:http://christhai.blog.51cto.com/1584747/1753662

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!