Defined Type: jboss::securitydomain

Defined in:
manifests/securitydomain.pp

Overview

Define: jboss::securitydomain

This defined type can be used to add and remove JBoss security domains. A security domain consists of configurations for authentication, authorization, security mapping, and auditing. It implements Java Authentication and Authorization Service (JAAS) declarative security.

See here: access.redhat.com/documentation/en-US/JBoss_Enterprise_Application_Platform/6.4/html/Security_Guide/sect-Security_Domains.html

Parameters

This type uses *JBoss module standard metaparameters*

name

**This is the namevar**. The name/ID of security domain.

ensure

Standard Puppet ensure parameter with values: ‘present’ and ‘absent’

code

The code for JBoss security domain

codeflag

The code flag for JBoss security domain

moduleoptions

Options for given Login module if form of a Puppet hash table

Parameters:

  • ensure (Any) (defaults to: 'present')
  • code (Any) (defaults to: undef)
  • codeflag (Any) (defaults to: undef)
  • moduleoptions (Any) (defaults to: undef)
  • profile (Any) (defaults to: $::jboss::profile)
  • controller (Any) (defaults to: $::jboss::controller)
  • runasdomain (Any) (defaults to: $::jboss::runasdomain)


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
54
55
# File 'manifests/securitydomain.pp', line 24

define jboss::securitydomain (
  $ensure        = 'present',
  $code          = undef,
  $codeflag      = undef,
  $moduleoptions = undef,
  $profile       = $::jboss::profile,
  $controller    = $::jboss::controller,
  $runasdomain   = $::jboss::runasdomain,
) {
  include jboss
  include jboss::internal::service
  include jboss::internal::runtime::node

  jboss_securitydomain { $name:
    ensure        => $ensure,
    code          => $code,
    codeflag      => $codeflag,
    moduleoptions => $moduleoptions,
    runasdomain   => $runasdomain,
    profile       => $profile,
    controller    => $controller,
    ctrluser      => $jboss::internal::runtime::node::username,
    ctrlpasswd    => $jboss::internal::runtime::node::password,
    require       => Anchor['jboss::package::end'],
  }

  if jboss_to_bool($::jboss_running) {
    Jboss_securitydomain[$name] ~> Service[$jboss::internal::service::servicename]
  } else {
    Anchor['jboss::service::end'] -> Jboss_securitydomain[$name] ~> Exec['jboss::service::restart']
  }
}