Last change
on this file since 764 was
699,
checked in by sebas@…, 14 years ago
|
el enable true, no esta necesario aqui
|
File size:
953 bytes
|
Line | |
---|
1 | # Example: |
---|
2 | # debproxy::activateclient { dist: |
---|
3 | # debproxyhost => "debproxy-ubuntu", |
---|
4 | # } |
---|
5 | |
---|
6 | define debproxy::activateclient ( $debproxyhost ) { |
---|
7 | file { "/etc/apt/apt.conf.d/01proxy": |
---|
8 | ensure => "present", |
---|
9 | content => "Acquire::http { Proxy \"http://$debproxyhost:3142\"; };\n", |
---|
10 | } |
---|
11 | } |
---|
12 | |
---|
13 | |
---|
14 | class debproxy::server { |
---|
15 | package { "apt-cacher": ensure => installed } |
---|
16 | |
---|
17 | file { "/etc/default/apt-cacher": ensure => present, checksum => mtime } |
---|
18 | |
---|
19 | line { aptcacher_off: |
---|
20 | file => "/etc/default/apt-cacher", |
---|
21 | line => 'AUTOSTART=0', |
---|
22 | ensure => absent, |
---|
23 | require => Package["apt-cacher"] |
---|
24 | } |
---|
25 | line { aptcacher_on: |
---|
26 | file => "/etc/default/apt-cacher", |
---|
27 | line => 'AUTOSTART=1', |
---|
28 | ensure => present, |
---|
29 | require => Package["apt-cacher"] |
---|
30 | } |
---|
31 | |
---|
32 | service { "apt-cacher": |
---|
33 | ensure => running, |
---|
34 | subscribe => [ Package["apt-cacher"], file["/etc/default/apt-cacher"]] |
---|
35 | } |
---|
36 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.