aboutsummaryrefslogtreecommitdiff
path: root/manifests/resources.pp
blob: e6b6df9ea1473621126e9c397d764a1826829e72 (plain)
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
class nodo::resources {
  # Website resources
  if defined("websites::resources") {
    class { "websites::resources": }
  }

  # Packages
  $packages = hiera('packages', {})
  create_resources('package', $packages)

  # Files
  $files = hiera('files', {})
  create_resources('file', $files)

  # File lines
  $file_lines = hiera('file_lines', {})
  create_resources('file_line', $file_lines)

  # Virtual machines
  $vms = hiera('virtual::machines', {})
  create_resources('nodo::subsystem::virtual::instance', $vms)

  # Users
  $users = hiera('users', {})
  create_resources('user::manage', $users)

  # Cron entries
  $cron = hiera('cron::jobs', {})
  create_resources('cron', $cron)

  # Hosts
  $hosts = hiera('hosts::jobs', {})
  create_resources('host', $hosts)
}