From 06396f5fc343321ca7f696f4b08ed0cb7c2ad8b2 Mon Sep 17 00:00:00 2001 From: Julien Godin Date: Thu, 21 Mar 2024 12:39:41 +0100 Subject: [PATCH] Feat: Allow to download from a login/password protected URL Signed-off-by: Julien Godin --- manifests/download.pp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/manifests/download.pp b/manifests/download.pp index e8593820..d7f6377f 100644 --- a/manifests/download.pp +++ b/manifests/download.pp @@ -28,6 +28,12 @@ # @param url # Full URL # +# @param username +# Username for the URL +# +# @param password +# Password for the URL +# # @param jce # Install Oracles Java Cryptographic Extensions into the JRE or JDK # @@ -62,6 +68,8 @@ Optional[String] $proxy_server = undef, Optional[Enum['none', 'http', 'https', 'ftp']] $proxy_type = undef, Optional[String] $url = undef, + Optional[String] $username = undef, + Optional[String] $password = undef, Boolean $jce = false, Optional[String] $jce_url = undef, Optional[String] $basedir = undef, @@ -258,6 +266,8 @@ archive { $destination : ensure => present, source => $source, + username => $username, + password => $password, extract_path => '/tmp', cleanup => false, creates => $creates_path, @@ -309,6 +319,8 @@ extract_path => $jce_path, extract_flags => '-oj', creates => "${jce_path}/US_export_policy.jar", + username => $username, + password => $password, cleanup => false, proxy_server => $proxy_server, proxy_type => $proxy_type,