Defined Type: visualdiff::server

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

Overview

FIXME: This is currently not enabled and configured. To be done.

The user-facing webapp that can be used to generate one off visual diffs.

Parameters

instance_name

Name of the visual-diffing service.

webapp_port

The port for the webapp. Default: 8012.

Parameters:

  • instance_name (Any)
  • webapp_port (Any) (defaults to: 8012)


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
# File 'modules/visualdiff/manifests/server.pp', line 14

define visualdiff::server(
    $instance_name,
    $webapp_port = 8012,
) {
    file { "/etc/visualdiff/${instance_name}.config.js":
        content => template("visualdiff/${instance_name}.config.js.erb"),
        owner   => 'root',
        group   => 'root',
        mode    => '0444',
        notify  => Service[$instance_name],
    }

    file { "/lib/systemd/system/${instance_name}.service":
        source => "puppet:///modules/visualdiff/${instance_name}.systemd.service",
        owner  => 'root',
        group  => 'root',
        mode   => '0444',
        notify => Service[$instance_name],
    }

    service { $instance_name:
        ensure  => running,
        require => [
            File["/etc/visualdiff/${instance_name}.config.js"],
            File["/lib/systemd/system/${instance_name}.service"],
        ],
    }
}