-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathinit.pp
76 lines (73 loc) · 2.22 KB
/
init.pp
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# == Class: oracle_dbfs
#
# This module configure the Oracle DBFS as a Unix Service on RHEL 6 systems (should work on 7 in compatibility)
#
# === Parameters
#
# [*user*]
# Oracle user
# [*group*]
# Oracle group.
# [*oracle_base*]
# Oracle base installation.
# [*oracle_home*]
# oracle home.
# [*cwallet*]
# Wallet file.
# [*ewallet*]
# Wallet file.
# [*tnsnames*]
# tnsnames.ora file content.
# [*sqlnet*]
# sqlnet.ora file content.
# [*user_allow_other*]
# configure "allow_other" in /etc/fuse.conf if true.
# [*service_name*]
# service name for mounting the remote fs.
# [*mounts*]
# Array of mount points and relative configuration.
#
# Sample usage:
# include oracle_dbfs {
# user => 'oracle',
# group => 'dba',
# oracle_base => '/usr/ora11g/app/oracle',
# oracle_home => '/usr/ora11g/app/oracle/product/11.2.0.4/client',
# ewallet => 'ewallet content',
# cwallet => 'cwallet content',
# tnsnames => 'tnsnames content',
# sqlnet => 'sqlnet content',
# mounts => {
# '/mnt/dbfs' => {
# 'conn_string' => 'dbfs@DBFS',
# 'mount_point' => '/mnt/dbfs',
# },
# }
# }
class oracle_dbfs (
$cwallet = $oracle_dbfs::params::cwallet,
$ewallet = $oracle_dbfs::params::ewallet,
$mounts = $oracle_dbfs::params::mounts,
$user_allow_other = $oracle_dbfs::params::user_allow_other,
$config_dir = $oracle_dbfs::params::config_dir,
$tnsnames = $oracle_dbfs::params::tnsnames,
$sqlnet = $oracle_dbfs::params::sqlnet,
$user = $oracle_dbfs::params::user,
$group = $oracle_dbfs::params::group,
$oracle_base = $oracle_dbfs::params::oracle_base,
$oracle_home = $oracle_dbfs::params::oracle_home,
$service_name = $oracle_dbfs::params::service_name,
) inherits oracle_dbfs::params {
# validate parameters here
validate_absolute_path($config_dir)
validate_bool($user_allow_other)
validate_string($user)
validate_string($group)
validate_absolute_path($oracle_base)
validate_absolute_path($oracle_home)
validate_string($service_name)
class { 'oracle_dbfs::install': } ->
class { 'oracle_dbfs::config': } ~>
class { 'oracle_dbfs::service': } ->
Class['oracle_dbfs']
}