summaryrefslogtreecommitdiff
path: root/manifests/daemon/directory.pp
blob: d877a8613241dbe7e29e4dfac8f945bed9318a4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# directory advertising
define tor::daemon::directory (
  $port             = 0,
  $listen_addresses = [],
  $port_front_page  = '/etc/tor/tor-exit-notice.html',
  $ensure           = present ) {

  concat::fragment { '06.directory':
    ensure  => $ensure,
    content => template('tor/torrc.directory.erb'),
    owner   => 'debian-tor',
    group   => 'debian-tor',
    mode    => '0644',
    order   => 06,
    target  => $tor::daemon::config_file,
  }

  file { '/etc/tor/tor-exit-notice.html':
    ensure  => $ensure,
    source  => 'puppet:///modules/tor/tor-exit-notice.html',
    require => File['/etc/tor'],
    owner   => 'debian-tor',
    group   => 'debian-tor',
    mode    => '0644',
  }
}