Skip to content
This repository has been archived by the owner on Apr 21, 2023. It is now read-only.

Commit

Permalink
Added version parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
jorritfolmer committed Jan 8, 2016
1 parent 49698df commit f703486
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 10 deletions.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ node 'splunk-cidx1.internal.corp.tld',
name and email This is a hash with 3 members:

- `hash` (SHA512 hash of the admin password)
- `pass` (Plaintext password, only used for search heads to add search peers in distributed search)
- `fn` (Full name)
- `email` (Email address)

Expand Down Expand Up @@ -344,6 +345,11 @@ node 'splunk-cidx1.internal.corp.tld',
This is useful if you want to retain one central deployment server instead of
multiple, for example one for each DMZ. Defaults to undef.

#### `version`

Optional. Specify the SPlunk version to use.
For example to install the 6.2.2 version: `verion => '6.2.2-255606'`.

## Compatibility

Requires Splunk and Splunkforwarders >= 6.2.0.
Expand All @@ -353,6 +359,11 @@ If you have version >= 6.2.0 servers but with stock settings from a previous Spl

## Changelog

### 1.0.4

- Optionally specify Splunk version to install
- Merged PR #1 from @timidri

### 1.0.3

- Added `ds_intermediate` parameter to create a deployment server that can deploy apps from an another upstream deployment server.
Expand Down Expand Up @@ -386,7 +397,6 @@ Initial release:

## Roadmap

- Optionally specify Splunk version to install
- Search head clustering: search head
- Search head clustering: deployer
- Distributed Management Console
Expand Down
9 changes: 5 additions & 4 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,16 @@
$dhparamsize_intermediate = $splunk::params::dhparamsize_intermediate,
$ecdhcurvename_intermediate = $splunk::params::ecdhcurvename_intermediate,
$inputport = $splunk::params::inputport,
$httpport = $splunk::params::httpport,
$kvstoreport = $splunk::params::kvstoreport,
$httpport = $splunk::params::httpport,
$kvstoreport = $splunk::params::kvstoreport,
$tcpout = $splunk::params::tcpout,
$searchpeers = $splunk::params::searchpeers,
$admin = $splunk::params::admin,
$searchpeers = $splunk::params::searchpeers,
$admin = $splunk::params::admin,
$clustering = $splunk::params::clustering,
$service = $splunk::params::service,
$useACK = $splunk::params::useACK,
$ds_intermediate = $splunk::params::ds_intemediate,
$version = $splunk::params::version,
) inherits splunk::params {

if $type == 'uf' {
Expand Down
16 changes: 12 additions & 4 deletions manifests/installed.pp
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,24 @@
class splunk::installed (
$package = $splunk::package,
$splunk_home = $splunk::splunk_home,
$splunk_os_user = $splunk::splunk_os_user
$splunk_os_user = $splunk::splunk_os_user,
$version = $splunk::version
) {
package { $package:
ensure => installed,
if $version == undef {
package { $package:
ensure => installed,
}
} else {
package { $package:
ensure => "${version}",
}
}
exec { 'splunk enable boot-start etcetera':
command => "${splunk_home}/bin/splunk enable boot-start -user ${splunk_os_user} --accept-license --answer-yes --no-prompt",
path => ["${splunk_home}/bin", '/bin', '/sbin', '/usr/bin', '/usr/sbin'],
require => Package[$package],
creates => "${splunk_home}/etc/system/local/server.conf",
}
}
}


3 changes: 2 additions & 1 deletion manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
enable => true,
ensure => undef,
}
$useACK = false
$useACK = false
$ds_intermediate = undef
$version = undef
}

0 comments on commit f703486

Please sign in to comment.