Change some resources names
This commit is contained in:
parent
90c18985f9
commit
09e9960e51
@ -2,7 +2,7 @@
|
|||||||
class bind::chroot::manual(
|
class bind::chroot::manual(
|
||||||
$chroot_dir = $::bind::defaults::chroot_dir,
|
$chroot_dir = $::bind::defaults::chroot_dir,
|
||||||
) inherits bind::defaults {
|
) inherits bind::defaults {
|
||||||
exec { 'mkdir-p-$chroot_dir':
|
exec { 'make-bind-chroot-dir':
|
||||||
command => "mkdir -p ${::bind::defaults::chroot_dir}",
|
command => "mkdir -p ${::bind::defaults::chroot_dir}",
|
||||||
path => ['/bin', '/usr/bin'],
|
path => ['/bin', '/usr/bin'],
|
||||||
creates => $::bind::defaults::chroot_dir,
|
creates => $::bind::defaults::chroot_dir,
|
||||||
@ -16,7 +16,7 @@ class bind::chroot::manual(
|
|||||||
"${::bind::defaults::chroot_dir}/var/run"]:
|
"${::bind::defaults::chroot_dir}/var/run"]:
|
||||||
ensure => directory,
|
ensure => directory,
|
||||||
mode => '0661',
|
mode => '0661',
|
||||||
require => Exec['mkdir-p-$chroot_dir'],
|
require => Exec['make-bind-chroot-dir'],
|
||||||
}
|
}
|
||||||
|
|
||||||
file { ["${::bind::defaults::chroot_dir}/var/cache/bind",
|
file { ["${::bind::defaults::chroot_dir}/var/cache/bind",
|
||||||
@ -24,29 +24,28 @@ class bind::chroot::manual(
|
|||||||
ensure => directory,
|
ensure => directory,
|
||||||
mode => '0775',
|
mode => '0775',
|
||||||
group => $::bind::defaults::bind_group,
|
group => $::bind::defaults::bind_group,
|
||||||
require => Exec['mkdir-p-$chroot_dir'],
|
require => Exec['make-bind-chroot-dir'],
|
||||||
}
|
}
|
||||||
|
|
||||||
exec { 'mknod-dev-null':
|
exec { 'bind-chroot-mknod-dev-null':
|
||||||
command => "mknod ${::bind::defaults::chroot_dir}/dev/null c 1 3",
|
command => "mknod ${::bind::defaults::chroot_dir}/dev/null c 1 3",
|
||||||
path => ['/bin', '/usr/bin'],
|
path => ['/bin', '/usr/bin'],
|
||||||
creates => "${::bind::defaults::chroot_dir}/dev/null",
|
creates => "${::bind::defaults::chroot_dir}/dev/null",
|
||||||
}
|
}
|
||||||
exec { 'mknod-dev-random':
|
-> exec { 'bind-chroot-mknod-dev-random':
|
||||||
command => "mknod ${::bind::defaults::chroot_dir}/dev/random c 1 8",
|
command => "mknod ${::bind::defaults::chroot_dir}/dev/random c 1 8",
|
||||||
path => ['/bin', '/usr/bin'],
|
path => ['/bin', '/usr/bin'],
|
||||||
creates => "${::bind::defaults::chroot_dir}/dev/random",
|
creates => "${::bind::defaults::chroot_dir}/dev/random",
|
||||||
}
|
}
|
||||||
exec { 'mknod-dev-urandom':
|
-> exec { 'bind-chroot-mknod-dev-urandom':
|
||||||
command => "mknod ${::bind::defaults::chroot_dir}/dev/urandom c 1 9",
|
command => "mknod ${::bind::defaults::chroot_dir}/dev/urandom c 1 9",
|
||||||
path => ['/bin', '/usr/bin'],
|
path => ['/bin', '/usr/bin'],
|
||||||
creates => "${::bind::defaults::chroot_dir}/dev/urandom",
|
creates => "${::bind::defaults::chroot_dir}/dev/urandom",
|
||||||
}
|
}
|
||||||
file { [ "${::bind::defaults::chroot_dir}/dev/null",
|
-> file { [ "${::bind::defaults::chroot_dir}/dev/null",
|
||||||
"${::bind::defaults::chroot_dir}/dev/random",
|
"${::bind::defaults::chroot_dir}/dev/random",
|
||||||
"${::bind::defaults::chroot_dir}/dev/urandom"]:
|
"${::bind::defaults::chroot_dir}/dev/urandom"]:
|
||||||
mode => '0660',
|
mode => '0660',
|
||||||
require => [ Exec['mknod-dev-null'], Exec['mknod-dev-random'], Exec['mknod-dev-urandom'] ],
|
|
||||||
}
|
}
|
||||||
exec { 'mv-etc-bind-into-jailed-etc':
|
exec { 'mv-etc-bind-into-jailed-etc':
|
||||||
command => "mv ${::bind::defaults::confdir} ${::bind::defaults::chroot_dir}${::bind::defaults::confdir}",
|
command => "mv ${::bind::defaults::confdir} ${::bind::defaults::chroot_dir}${::bind::defaults::confdir}",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user