diff --git a/.travis.yml b/.travis.yml
index f0c6445..85b7957 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -2,6 +2,7 @@ language: ruby
rvm:
- 1.9.3
- ruby-head
+bundler_args: --without development
script:
- "bundle exec rake lint"
- "bundle exec rake spec SPEC_OPTS='--format documentation'"
@@ -21,4 +22,4 @@ matrix:
gemfile: .gemfile
notifications:
email:
- - travisci@tylerwalts.com
+ - eurides.baptistella@gmail.com
diff --git a/README.md b/README.md
index 3b5e86a..fe13a1a 100644
--- a/README.md
+++ b/README.md
@@ -111,3 +111,5 @@ site.pp:
* Boolean to indicate if the installed java version is linked as the default java, javac etc...
* ensure
* Boolean to disable anything from happening (absent/removal not supported yet)
+* download_timeout
+ * Integer Timeout for download (wget) in seconds. Default is 600s
diff --git a/manifests/init.pp b/manifests/init.pp
index 8ea4cd8..eca028b 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -42,23 +42,28 @@
# String. Specifies if jdk should be installed or absent
# Defaults to installed.
#
+# [* download_timeout *]
+# Integer. Timeout for download (wget) in seconds
+# Defaults to 600 seconds.
+#
class jdk_oracle(
- $version = hiera('jdk_oracle::version', '8' ),
- $version_update = hiera('jdk_oracle::version_update', 'default' ),
- $version_build = hiera('jdk_oracle::version_build', 'default' ),
- $install_dir = hiera('jdk_oracle::install_dir', '/opt' ),
- $use_cache = hiera('jdk_oracle::use_cache', false ),
- $cache_source = 'puppet:///modules/jdk_oracle/',
- $platform = hiera('jdk_oracle::platform', 'x64' ),
- $jce = hiera('jdk_oracle::jce', false ),
- $default_java = hiera('jdk_oracle::default_java', true ),
- $ensure = 'installed'
+ $version = hiera('jdk_oracle::version', '8' ),
+ $version_update = hiera('jdk_oracle::version_update', 'default' ),
+ $version_build = hiera('jdk_oracle::version_build', 'default' ),
+ $install_dir = hiera('jdk_oracle::install_dir', '/opt' ),
+ $use_cache = hiera('jdk_oracle::use_cache', false ),
+ $cache_source = 'puppet:///modules/jdk_oracle/',
+ $platform = hiera('jdk_oracle::platform', 'x64' ),
+ $jce = hiera('jdk_oracle::jce', false ),
+ $default_java = hiera('jdk_oracle::default_java', true ),
+ $ensure = 'installed',
+ $download_timeout = hiera('jdk_oracle::download_timeout', 600 ),
) {
- $default_8_update = '11'
- $default_8_build = '12'
- $default_7_update = '67'
- $default_7_build = '01'
+ $default_8_update = '51'
+ $default_8_build = '16'
+ $default_7_update = '80'
+ $default_7_build = '15'
$default_6_update = '45'
$default_6_build = '06'
@@ -143,8 +148,8 @@
exec { 'get_jdk_installer':
cwd => $install_dir,
creates => "${install_dir}/${installerFilename}",
- command => "wget -c --no-cookies --no-check-certificate --header \"Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com\" --header \"Cookie: oraclelicense=accept-securebackup-cookie\" \"${javaDownloadURI}\" -O ${installerFilename}",
- timeout => 600,
+ command => "wget -c -T ${download_timeout} --no-cookies --no-check-certificate --header \"Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com\" --header \"Cookie: oraclelicense=accept-securebackup-cookie\" \"${javaDownloadURI}\" -O ${installerFilename}",
+ timeout => $download_timeout,
require => Package['wget'],
}
@@ -284,8 +289,8 @@
exec { 'get_jce_package':
cwd => $install_dir,
creates => "${install_dir}/${jceFilename}",
- command => "wget -c --no-cookies --no-check-certificate --header \"Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com\" --header \"Cookie: oraclelicense=accept-securebackup-cookie\" \"${jceDownloadURI}\" -O ${jceFilename}",
- timeout => 600,
+ command => "wget -c -T ${download_timeout} --no-cookies --no-check-certificate --header \"Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com\" --header \"Cookie: oraclelicense=accept-securebackup-cookie\" \"${jceDownloadURI}\" -O ${jceFilename}",
+ timeout => $download_timeout,
require => Package['wget'],
}