aboutsummaryrefslogtreecommitdiffstats
path: root/modules/mirror/manifests/init.pp
blob: 512b0463c6978a4a884dda9ae5f16d415e7f5c49 (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
28
29
30
31
32
33
34
35
36
37
38
39
40
class mirror {

    file { "update_timestamp":
        path => "/home/mirror/bin/update_timestamp",
        ensure => present,
        owner => mirror,
        group => mirror,
        mode => 755,
        content => template("mirror/update_timestamp")
    }

    file { "/home/mirror/bin/":
        ensure => directory,
        owner => mirror,
        group => mirror,
        mode => 755
    }

    group {"mirror":
        ensure => present,
    }

    user {"mirror":
        ensure => present,
        comment => "System user use to run mirror scripts",
        managehome => true,
        gid => mirror,
        shell => "/bin/bash",
    }


    cron { mirror:
        user => mirror,
        hour => 10,
        minute => 14,
        command => "~mirror/bin/update_timestamp",
        require => File["update_timestamp"],
    }

}