Skip to content

Commit

Permalink
Fix Download Timeout
Browse files Browse the repository at this point in the history
When downloading large plugins, it can timeout (e.g. ruby-runtime). The
archive::download supports a timeout value which defaults to 120
seconds, but this plugin class doesn’t have any support to override
this value. This allows for the ability to adjust the timeout value for
large plugins.

Error message when download timeout exceeds 120 seconds:

Error:
/Stage[main]/Jenkins::Plugins/Jenkins::Plugin[ruby-runtime]/Archive::Dow
nload[ruby-runtime.hpi]/Exec[download archive ruby-runtime.hpi and
check sum]/returns: change from notrun to 0 failed: Command exceeded
timeout
  • Loading branch information
mooreandrew committed Nov 7, 2015
1 parent 1d5c5c2 commit 580435a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions manifests/plugin.pp
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
$source = undef,
$digest_string = '',
$digest_type = 'sha1',
$timeout = 120,
# deprecated
$plugin_dir = undef,
$username = undef,
Expand Down Expand Up @@ -125,6 +126,7 @@
proxy_server => $proxy_server,
notify => Service['jenkins'],
require => File[$::jenkins::plugin_dir],
timeout => $timeout,
}

file { "${::jenkins::plugin_dir}/${plugin}" :
Expand Down

0 comments on commit 580435a

Please sign in to comment.