Defined Type: mrepo::iso

Defined in:
manifests/iso.pp

Overview

Class: mrepo::iso

This define downloads iso files

Parameters:

  • title

    Specifies the filename of the ISO file

  • source_url (Any)

    Specifies the URL portion to the path where the above ISO file is actually found. This parameter gets concatenated with the filename from title param, which then forms the whole URL to the ISO file.

  • repo (Any)

    Title of the mrepo::repo resources the ISO file belongs to



10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# File 'manifests/iso.pp', line 10

define mrepo::iso ($source_url, $repo) {
  include mrepo

  $target_file = "${mrepo::src_root}/iso/${name}"

  ensure_resource('file', "${mrepo::src_root}/iso", {
      'ensure' => 'directory',
      'owner'  => $mrepo::user,
      'group'  => $mrepo::group,
      'mode'   => '0644',
  })

  archive { $target_file:
    source  => "${source_url}/${name}",
    before  => Mrepo::Repo[$repo],
    require => File["${mrepo::src_root}/iso"],
  }
}