Puppet Class: profile::microsites::design

Defined in:
modules/profile/manifests/microsites/design.pp

Overview

SPDX-License-Identifier: Apache-2.0 design.wikimedia.org (T185282)

Parameters:

  • server_name (Stdlib::Fqdn) (defaults to: lookup('profile::microsites::design::server_name'))
  • server_admin (String) (defaults to: lookup('profile::microsites::design::server_admin'))


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
41
42
43
44
45
46
47
48
49
# File 'modules/profile/manifests/microsites/design.pp', line 3

class profile::microsites::design(
  Stdlib::Fqdn $server_name = lookup('profile::microsites::design::server_name'),
  String $server_admin = lookup('profile::microsites::design::server_admin'),
) {

    httpd::site { 'design.wikimedia.org':
        content => template('profile/design/design.wikimedia.org-httpd.erb'),
    }

    $design_blog_repo_dir = '/srv/org/wikimedia/design-blog'
    $design_blog_docroot  = "${design_blog_repo_dir}/_site"

    wmflib::dir::mkdir_p($design_blog_repo_dir)
    wmflib::dir::mkdir_p('/srv/org/wikimedia/design')
    wmflib::dir::mkdir_p('/srv/org/wikimedia/design-strategy')

    git::clone { 'design/landing-page':
        ensure    => 'latest',
        source    => 'gerrit',
        directory => '/srv/org/wikimedia/design',
        branch    => 'master',
    }

    git::clone { 'design/strategy':
        ensure    => 'latest',
        source    => 'gerrit',
        directory => '/srv/org/wikimedia/design-strategy',
        branch    => 'master',
    }

    git::clone { 'design/blog':
        ensure    => 'latest',
        source    => 'gerrit',
        directory => $design_blog_repo_dir,
        branch    => 'master',
    }

    scap::target { 'design/style-guide':
        deploy_user => 'deploy-design',
    }

    file { '/srv/org/wikimedia/design-style-guide':
        ensure  => 'link',
        target  => '/srv/deployment/design/style-guide',
        require => Scap::Target['design/style-guide'],
    }
}