Skip to content

Commit

Permalink
Pass through environment to staging, so we can set a proxy to downloa…
Browse files Browse the repository at this point in the history
…d tomcat
  • Loading branch information
edestecd committed Oct 31, 2016
1 parent b24ba47 commit 3cdb860
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
2 changes: 2 additions & 0 deletions manifests/install.pp
Expand Up @@ -6,6 +6,7 @@
# source options
$source_url = undef,
$source_strip_first_dir = true,
$environment = undef,
$user = undef,
$group = undef,
$manage_user = undef,
Expand Down Expand Up @@ -44,6 +45,7 @@
manage_home => $_manage_home,
source_url => $source_url,
source_strip_first_dir => $source_strip_first_dir,
environment => $environment,
user => $_user,
group => $_group,
}
Expand Down
19 changes: 11 additions & 8 deletions manifests/install/source.pp
Expand Up @@ -14,6 +14,7 @@
$manage_home,
$source_url,
$source_strip_first_dir,
$environment,
$user,
$group,
) {
Expand All @@ -39,7 +40,8 @@
}

ensure_resource('staging::file',$filename, {
'source' => $source_url,
'source' => $source_url,
'environment' => $environment,
})

# FM-5578 workaround for strict umodes
Expand All @@ -53,12 +55,13 @@
})

staging::extract { "${name}-${filename}":
source => "${::staging::path}/tomcat/${filename}",
target => $catalina_home,
require => Staging::File[$filename],
unless => "test -f ${catalina_home}/NOTICE",
user => $user,
group => $group,
strip => $_strip,
source => "${::staging::path}/tomcat/${filename}",
target => $catalina_home,
require => Staging::File[$filename],
unless => "test -f ${catalina_home}/NOTICE",
user => $user,
group => $group,
environment => $environment,
strip => $_strip,
}
}

0 comments on commit 3cdb860

Please sign in to comment.