Defined Type: hpe3par::device

Defined in:
manifests/device.pp

Overview

Define: hpe3par::device

Enables the management of a HPE 3PAR Storage System on a Puppet node’s device.conf.

This defined type should be used on a proxy node that manages the HPE 3PAR Storage System.

Parameters:

hostname

The IP or DNS name of the HPE 3PAR Storage System.

username

The username for the HPE 3PAR WSAPI.

password

The password for the HPE 3PAR WSAPI.

Parameters:

  • hostname (Any)
  • username (Any)
  • password (Any)
  • target (Any) (defaults to: undef)


31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# File 'manifests/device.pp', line 31

define hpe3par::device (
  $hostname,
  $username,
  $password,
  $target = undef,
) {
  validate_string($hostname)
  validate_string($username)
  validate_string($password)

  $device_config = pick($target, $::settings::deviceconfig)

  validate_absolute_path($device_config)

  augeas { "device.conf/${name}":
    lens    => 'Puppet_Device',
    incl    => $device_config,
    context => $device_config,
    changes => [
      "set ${name}/type hpe3par",
      "set ${name}/url https://${username}:${password}@${hostname}:8080",
    ]
  }
}