Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions manifests/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,15 @@
}
}
}
'Archlinux': {
if $java::use_java_home != undef {
file_line { 'java-home-environment':
path => '/etc/profile',
line => "JAVA_HOME=${$java::use_java_home}",
match => 'JAVA_HOME=',
}
}
}
default: {
# Do nothing.
}
Expand Down
5 changes: 2 additions & 3 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
# or other platform-specific options where there are multiple
# implementations available (eg: OpenJDK vs Oracle JDK).
#
#
# [*version*]
# The version of java to install. By default, this module simply ensures
# that java is present, and does not require a specific version.
Expand All @@ -36,8 +35,8 @@
# correct JVM is enabled.
#
# [*java_home*]
# The path to where the JRE is installed. This will be set as an
# environment variable.
# The path to where the JRE is installed. This will be set as an
# environment variable.
#
# Actions:
#
Expand Down
15 changes: 15 additions & 0 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,21 @@
},
}
}
'Archlinux': {
$jdk_package = 'jdk8-openjdk'
$jre_package = 'jre8-openjdk'
$java_home = '/usr/lib/jvm/java-8-openjdk/jre/'
$java = {
'jdk' => {
'package' => $jdk_package,
'java_home' => $java_home,
},
'jre' => {
'package' => $jre_package,
'java_home' => $java_home,
},
}
}
default: { fail("unsupported platform ${::osfamily}") }
}
}