Puppet Class: profile::maps::apps

Defined in:
modules/profile/manifests/maps/apps.pp

Overview

Parameters:

  • cassandra_hosts (Array[String]) (defaults to: lookup('profile::cassandra::single_instance::seeds'))
  • cassandra_kartotherian_pass (String) (defaults to: lookup('profile::maps::cassandra::kartotherian_pass'))
  • cassandra_tilerator_pass (String) (defaults to: lookup('profile::maps::cassandra::tilerator_pass'))
  • cassandra_tileratorui_pass (String) (defaults to: lookup('profile::maps::cassandra::tileratorui_pass'))
  • pgsql_kartotherian_pass (String) (defaults to: lookup('profile::maps::osm_master::kartotherian_pass'))
  • pgsql_tilerator_pass (String) (defaults to: lookup('profile::maps::osm_master::tilerator_pass'))
  • pgsql_tileratorui_pass (String) (defaults to: lookup('profile::maps::osm_master::tileratorui_pass'))
  • redis_server (String) (defaults to: lookup('profile::maps::apps::redis_server'))
  • redis_pass (String) (defaults to: lookup('profile::maps::apps::redis_pass'))
  • kartotherian_storage_id (String) (defaults to: lookup('profile::maps::apps::kartotherian_storage_id'))
  • tilerator_storage_id (String) (defaults to: lookup('profile::maps::apps::tilerator_storage_id'))
  • wikidata_query_service (String) (defaults to: lookup('profile::maps::apps::wikidata_query_service'))
  • tilerator_ncpu_ratio (Float[0.0, 1.0]) (defaults to: lookup('profile::maps::apps::tilerator_ncpu_ratio'))
  • tilerator_enable (Boolean) (defaults to: lookup('profile::maps::apps::tilerator_enable'))


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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# File 'modules/profile/manifests/maps/apps.pp', line 1

class profile::maps::apps(
    Array[String] $cassandra_hosts = lookup('profile::cassandra::single_instance::seeds'),
    String $cassandra_kartotherian_pass = lookup('profile::maps::cassandra::kartotherian_pass'),
    String $cassandra_tilerator_pass = lookup('profile::maps::cassandra::tilerator_pass'),
    String $cassandra_tileratorui_pass = lookup('profile::maps::cassandra::tileratorui_pass'),
    String $pgsql_kartotherian_pass = lookup('profile::maps::osm_master::kartotherian_pass'),
    String $pgsql_tilerator_pass = lookup('profile::maps::osm_master::tilerator_pass'),
    String $pgsql_tileratorui_pass = lookup('profile::maps::osm_master::tileratorui_pass'),
    String $redis_server = lookup('profile::maps::apps::redis_server'),
    String $redis_pass = lookup('profile::maps::apps::redis_pass'),
    String $kartotherian_storage_id = lookup('profile::maps::apps::kartotherian_storage_id'),
    String $tilerator_storage_id = lookup('profile::maps::apps::tilerator_storage_id'),
    String $wikidata_query_service = lookup('profile::maps::apps::wikidata_query_service'),
    Float[0.0, 1.0] $tilerator_ncpu_ratio = lookup('profile::maps::apps::tilerator_ncpu_ratio'),
    Boolean $tilerator_enable = lookup('profile::maps::apps::tilerator_enable'),
) {

    $use_nodejs10 = true

    $contact_groups = 'admins,team-interactive'

    $num_workers = floor($::processorcount * $tilerator_ncpu_ratio)

    class { '::tilerator':
        cassandra_servers => $cassandra_hosts,
        cassandra_pass    => $cassandra_tilerator_pass,
        pgsql_pass        => $pgsql_tilerator_pass,
        redis_server      => $redis_server,
        redis_pass        => $redis_pass,
        contact_groups    => $contact_groups,
        storage_id        => $tilerator_storage_id,
        num_workers       => $num_workers,
        use_nodejs10      => $use_nodejs10,
        enable            => $tilerator_enable,
    }

    class { '::tilerator::ui':
        cassandra_servers => $cassandra_hosts,
        cassandra_pass    => $cassandra_tileratorui_pass,
        pgsql_pass        => $pgsql_tileratorui_pass,
        redis_server      => $redis_server,
        redis_pass        => $redis_pass,
        contact_groups    => $contact_groups,
        storage_id        => $tilerator_storage_id,
        use_nodejs10      => $use_nodejs10,
    }

    class { 'kartotherian':
        cassandra_servers      => $cassandra_hosts,
        cassandra_pass         => $cassandra_kartotherian_pass,
        pgsql_pass             => $pgsql_kartotherian_pass,
        contact_groups         => $contact_groups,
        storage_id             => $kartotherian_storage_id,
        tilerator_storage_id   => $tilerator_storage_id,
        wikidata_query_service => $wikidata_query_service,
        use_nodejs10           => $use_nodejs10,
    }

    # those fonts are needed for the new maps style (brighmed)
    ensure_packages(['fonts-noto', 'fonts-noto-cjk', 'fonts-noto-unhinted'])
}