Skip to content

Commit

Permalink
Merge pull request #2 from mpvvliet/master
Browse files Browse the repository at this point in the history
Support for various different options (funny passwords, classifiers, variables in output parameter)
  • Loading branch information
cescoffier committed Jan 20, 2012
2 parents 3ca1a16 + 46cb3ca commit 457f693
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions manifests/artifact.pp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
include nexus

if ($nexus::authentication) {
$args = "-u ${nexus::user} -p ${nexus::pwd}"
$args = "-u ${nexus::user} -p '${nexus::pwd}'"
} else {
$args = ""
}
Expand All @@ -46,17 +46,17 @@
$cmd = "/opt/nexus-script/download-artifact-from-nexus.sh -a ${gav} -e ${packaging} ${$includeClass} -n ${nexus::NEXUS_URL} -r ${repository} -o ${output} $args -v"

if $ensure == present {
exec { "Download ${gav}":
exec { "Download ${gav}-${classifier}":
command => $cmd,
unless => '/bin/test -f ${output}'
unless => "/bin/test -f ${output}"
}
} elsif $ensure == absent {
file { "Remove ${gav}":
file { "Remove ${gav}-${classifier}":
path => $output,
ensure => absent
}
} else {
exec { "Download ${gav}":
exec { "Download ${gav}-${classifier}":
command => $cmd,
}
}
Expand Down

0 comments on commit 457f693

Please sign in to comment.