Puppet Class: jboss::instance_5_uninstall
- Defined in:
- manifests/instance_5_uninstall.pp
Overview
Uninstalls JBoss-5.1.0 instance TODO To be completed and verified
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 |
# File 'manifests/instance_5_uninstall.pp', line 3
class jboss::instance_5_uninstall (
$instance_name = $::instance_to_remove_name,
$ip = $::instance_to_remove_ip,
$environment = $::environment,) {
$ip_alias = "${instance_name}-${environment}"
# Servizio
service { "jboss-${instance_name}":
ensure => stopped,
enable => false,
hasstatus => false,
pattern => "-c ${instance_name}",
stop => "/usr/local/bin/manage-jboss-instance ${instance_name} stop",
path => '/etc/init.d',
} ->
# Profilo
file { "/opt/jboss/server/${instance_name}":
ensure => absent,
force => true,
} ->
# Script di avvio
file { "/opt/jboss/bin/run-${instance_name}.sh":
ensure => absent,
} ->
# Directory log del server
file { "/var/log/jboss/server/${instance_name}":
ensure => absent,
force => true,
} ->
# Nome logico istanza in /etc/hosts
host { $ip_alias:
ensure => absent,
ip => $ip,
}
}
|