Add proxy options for Oracle Java

This commit is contained in:
Chris Edester
2016-07-05 09:46:47 -04:00
parent 91871b1408
commit 25c1ac83ce
2 changed files with 16 additions and 0 deletions

View File

@@ -133,6 +133,12 @@ Install or remove the package.
#####`oracle_url`
Official Oracle URL to download the binaries from.
#####`proxy_server`
Specify a proxy server, with port number if needed. ie: https://example.com:8080. (passed to archive)
#####`proxy_type`
Proxy server type (none|http|https|ftp). (passed to archive)
###Facts
The java module includes a few facts to describe the version of Java installed on the system:

View File

@@ -34,6 +34,12 @@
# [*oracle_url*]
# Official Oracle URL to download binaries from.
#
# [*proxy_server*]
# Specify a proxy server, with port number if needed. ie: https://example.com:8080. (passed to archive)
#
# [*proxy_type*]
# Proxy server type (none|http|https|ftp). (passed to archive)
#
# Variables
# [*release_major*]
# Major version release number for java_se. Used to construct download URL.
@@ -86,6 +92,8 @@ define java::oracle (
$version_minor = undef,
$java_se = 'jdk',
$oracle_url = 'http://download.oracle.com/otn-pub/java/jdk/',
$proxy_server = undef,
$proxy_type = undef,
) {
# archive module is used to download the java package
@@ -216,6 +224,8 @@ define java::oracle (
extract_path => '/tmp',
cleanup => false,
creates => $creates_path,
proxy_server => $proxy_server,
proxy_type => $proxy_type,
}->
case $::kernel {
'Linux' : {