Puppet Class: sap::management::ads_fonts

Defined in:
manifests/management/ads_fonts.pp

Summary

Deploys font and XDC files to ADS systems

Overview

Parameters:

  • system_ids (Hash[Sap::SID, Sap::SIDConfigEntry]) (defaults to: $sap::system_ids)

    Sourced directly from the parent system_ids parameter on the SAP class. See that class for further detail.

  • deployed_fonts (Sap::SourcedFile) (defaults to: $sap::deployed_fonts)

    Hash with a list of fonts to deploy and their source locations. Each file in this structure will be installed in ‘/usr/sap/$SAPSYSTEMNAME/SYS/global/AdobeDocumentServices/FontManagerService/fonts/customer/` for each local SID with the ADS component enabled.

  • deployed_xdc (Sap::SourcedFile) (defaults to: $sap::deployed_xdc)

    Hash with a list of xdc files to deploy and their source locations. Each file in this structure will be installed in ‘/usr/sap/$sid/SYS/global/AdobeDocumentServices/lib/XDC/Customer/` for each local SID with the ADS component enabled.



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
# File 'manifests/management/ads_fonts.pp', line 18

class sap::management::ads_fonts (
  Hash[Sap::SID, Sap::SIDConfigEntry] $system_ids = $sap::system_ids,
  Sap::SourcedFile $deployed_fonts                = $sap::deployed_fonts,
  Sap::SourcedFile $deployed_xdc                  = $sap::deployed_xdc,
) {

  # Loop through all sids
  $system_ids.each |$sid, $sid_data| {
    $sid_lower = downcase($sid)

    # Skip non ADS systems
    unless('ads' in $sid_data['components']) { next() }

    # Deploy requested font
    $deployed_fonts.each |$font_file, $font_file_source| {
      file { "/usr/sap/${sid}/SYS/global/AdobeDocumentServices/FontManagerService/fonts/customer/${font_file}":
        ensure => 'file',
        source => $font_file_source,
        mode   => '0644',
        owner  => "${sid_lower}adm",
        group  => 'sapsys',
      }
    }

    # Deploy requested xdc files
    $deployed_xdc.each |$xdc_file, $xdc_file_source| {
      file { "/usr/sap/${sid}/SYS/global/AdobeDocumentServices/lib/XDC/Customer/${xdc_file}":
        ensure => 'file',
        source => $xdc_file_source,
        mode   => '0644',
        owner  => "${sid_lower}adm",
        group  => 'sapsys',
      }
    }
  }
}