Puppet Class: visualdiff

Defined in:
modules/visualdiff/manifests/init.pp

Overview

Class: visualdiff

This module provides a standalone visual diffing service.



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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# File 'modules/visualdiff/manifests/init.pp', line 4

class visualdiff {

    $visualdiff_packages = [
        'nodejs',
        'npm',
        'uprightdiff',
    ]

    require_package($visualdiff_packages)

    group { 'visualdiff':
        ensure => present,
        system => true,
    }

    user { 'visualdiff':
        gid        => 'visualdiff',
        home       => '/srv/visualdiff',
        managehome => false,
        system     => true,
    }

    file { '/var/log/visualdiff':
        ensure => directory,
        owner  => 'visualdiff',
        group  => 'visualdiff',
        mode   => '0755',
    }

    file { '/etc/visualdiff':
        ensure => directory,
        owner  => 'root',
        group  => 'root',
        mode   => '0755',
    }

    git::clone { 'integration/visualdiff':
        branch    => 'ruthenium',
        owner     => 'root',
        group     => 'wikidev',
        directory => '/srv/visualdiff',
        before    => File['/srv/visualdiff/pngs'],
    }

    # visual-diff testreduce clients save the
    # parsoid and php parser screenshots and
    # the screenshot diff to this directory.
    file { '/srv/visualdiff/pngs':
        ensure => directory,
        owner  => 'testreduce',
        group  => 'testreduce',
        mode   => '0775',
    }

    # create an empty testrun.ids but only if it does not exist
    # don't change content in existing file (T215049)
    file { '/srv/visualdiff/testreduce/testrun.ids':
        ensure  => present,
        replace => false,
        content => 'puppet-init',
        owner   => 'testreduce',
        group   => 'testreduce',
        mode    => '0775',
    }
}