Skip to content

Commit

Permalink
Merge pull request #8 from sbitio/debian9-support
Browse files Browse the repository at this point in the history
Add Debian 9 support
  • Loading branch information
treydock committed Feb 22, 2018
2 parents e7c2ef0 + 7bb9846 commit b42821e
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ Hash that is used to define keycloak::client_template resources. Default is `{}`
This module has been tested on:

* CentOS 7 x86_64
* Debian 9 x86_64
* RedHat 7 x86_64

## Development
Expand Down
2 changes: 1 addition & 1 deletion manifests/install.pp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
ensure => 'present',
name => $keycloak::user,
forcelocal => true,
shell => '/sbin/nologin',
shell => $keycloak::user_shell,
gid => $keycloak::group,
uid => $keycloak::user_uid,
home => '/var/lib/keycloak',
Expand Down
9 changes: 8 additions & 1 deletion manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,21 @@
]

case $::osfamily {
'Debian': {
$service_name = 'keycloak'
$service_hasstatus = true
$service_hasrestart = true
$user_shell = '/usr/sbin/nologin'
}
'RedHat': {
$service_name = 'keycloak'
$service_hasstatus = true
$service_hasrestart = true
$user_shell = '/sbin/nologin'
}

default: {
fail("Unsupported osfamily: ${::osfamily}, module ${module_name} only support osfamily RedHat")
fail("Unsupported osfamily: ${::osfamily}, module ${module_name} only support osfamilies Debian and Redhat")
}
}

Expand Down
4 changes: 4 additions & 0 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
{
"operatingsystem": "Scientific",
"operatingsystemrelease": [ "7" ]
},
{
"operatingsystem": "Debian",
"operatingsystemrelease": [ "9" ]
}
],
"requirements": [
Expand Down

0 comments on commit b42821e

Please sign in to comment.