Puppet Class: iop::core_yuptoo

Defined in:
manifests/core_yuptoo.pp

Overview

Class: iop::core_yuptoo

Install and configure the core yuptoo

Parameters:

$image

The container image

$ensure

Ensure service is present or absent

Parameters:

  • image (String[1]) (defaults to: 'quay.io/iop/yuptoo:latest')
  • ensure (Enum['present', 'absent']) (defaults to: 'present')


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 'manifests/core_yuptoo.pp', line 11

class iop::core_yuptoo (
  String[1] $image = 'quay.io/iop/yuptoo:latest',
  Enum['present', 'absent'] $ensure = 'present',
) {
  include podman
  require iop::core_network

  podman::quadlet { 'iop-core-yuptoo':
    ensure       => $ensure,
    quadlet_type => 'container',
    user         => 'root',
    defaults     => {},
    require      => [
      Podman::Network['iop-core-network'],
    ],
    settings     => {
      'Unit'      => {
        'Description' => 'IOP Core Yuptoo Container',
      },
      'Container' => {
        'Image'         => $image,
        'ContainerName' => 'iop-core-yuptoo',
        'Network'       => 'iop-core-network',
        'Exec'          => 'python -m main',
        'Environment'   => [
          'BOOTSTRAP_SERVERS=iop-core-kafka:9092',
          'BYPASS_PAYLOAD_EXPIRATION=true',
        ],
      },
      'Service'   => {
        'Environment' => 'REGISTRY_AUTH_FILE=/etc/foreman/registry-auth.json',
        'Restart'     => 'on-failure',
      },
      'Install'   => {
        'WantedBy' => 'default.target',
      },
    },
  }
}