Add openjdk module
This commit is contained in:
parent
ea49680a0f
commit
34a7b9f98a
1 changed files with 44 additions and 0 deletions
44
openjdk/manifests/init.pp
Normal file
44
openjdk/manifests/init.pp
Normal file
|
@ -0,0 +1,44 @@
|
|||
# Install OpenJDK development environment.
|
||||
#
|
||||
class openjdk::jdk {
|
||||
|
||||
case $::operatingsystem {
|
||||
"centos","redhat": {
|
||||
package { "java-1.7.0-openjdk-devel":
|
||||
ensure => installed,
|
||||
}
|
||||
}
|
||||
"ubuntu": {
|
||||
package { "openjdk-7-jdk":
|
||||
ensure => installed,
|
||||
}
|
||||
}
|
||||
default: {
|
||||
fail("openjdk not supported on ${::operatingsystem}")
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
# Install OpenJDK runtime environment.
|
||||
#
|
||||
class openjdk::jre {
|
||||
|
||||
case $::operatingsystem {
|
||||
"centos","redhat": {
|
||||
package { "java-1.7.0-openjdk":
|
||||
ensure => installed,
|
||||
}
|
||||
}
|
||||
"ubuntu": {
|
||||
package { "openjdk-7-jre":
|
||||
ensure => installed,
|
||||
}
|
||||
}
|
||||
default: {
|
||||
fail("openjdk not supported on ${::operatingsystem}")
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Reference in a new issue