File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change 5656 } else {
5757 $_refresh = true
5858 }
59+ $apt_update_successful = @(" ASH" /$)
60+ for try in \$(seq ${apt::_update[' tries' ]} -1 1); do
61+ timeout ${apt::_update[' timeout' ]} ${apt::provider} update && exit 0
62+ [ \$try -eq 1 ] && exit \$?
63+ sleep 1
64+ done
65+ - ASH
5966 exec { 'apt_update' :
60- command => " ${apt::provider} update" ,
67+ command => " echo ${apt::provider} update FAILED " ,
6168 loglevel => $apt::_update [' loglevel' ],
6269 logoutput => ' on_failure' ,
70+ path => ' /bin:/usr/bin' ,
71+ provider => shell,
6372 refreshonly => $_refresh,
73+ returns => [-1], # This ensures a run-time failure.
6474 timeout => $apt::_update [' timeout' ],
65- tries => $apt::_update [' tries' ],
66- try_sleep => 1,
75+ unless => $apt_update_successful ,
6776 }
6877}
You can’t perform that action at this time.
0 commit comments