Closed
Bug 1035898
Opened 10 years ago
Closed 10 years ago
Bare Metal Provisioning 2008 Puppet: Correct Gapi manifest
Categories
(Infrastructure & Operations :: RelOps: Puppet, task)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: markco, Assigned: markco)
Details
(Whiteboard: [time=1:30])
Attachments
(1 file)
1.48 KB,
patch
|
dustin
:
review+
dustin
:
checked-in+
|
Details | Diff | Splinter Review |
> ::: modules/slave_secrets/manifests/google_api_key.pp
> @@ +12,2 @@
> > content => secret("google_api_key"),
> > + }
>
> This bit should be within the conditional for ensure == present and
> install_google_api_key.
>
> ::: modules/ssh/manifests/winfiles.pp
> @@ +1,4 @@
Windows is now included within the conditional:
class slave_secrets::google_api_key($ensure=present) {
include config
include dirs::builds
if ($ensure == 'present' and $config::install_google_api_key) {
case $::operatingsystem {
windows: {
file {
'C:/builds/gapi.data':
ensure => file,
content => secret("google_api_key"),
}
}
default: {
file {
"/builds/gapi.data":
content => secret("google_api_key"),
mode => 0644,
show_diff => false;
}
}
}
} else {
case $::operatingsystem {
windows: {
file {
'C:/builds/gapi.data':
ensure => absent;
}
}
default: {
file {
"/builds/gapi.data":
ensure => absent;
}
}
}
}
}
Assignee | ||
Updated•10 years ago
|
Assignee: relops → mcornmesser
Comment 1•10 years ago
|
||
Looks good. You could shrink that a little with $gapi_file = $::operatingsystem? { windows => 'c:/builds/gapi.data', default => '/builds/gapi.data' } .. file { $gapi_file: ensure => file, content => secret("google_api_key"), } with no need for both conditionals.
Assignee | ||
Updated•10 years ago
|
Whiteboard: [time=1:30]
Assignee | ||
Comment 2•10 years ago
|
||
Attachment #8475225 -
Flags: review?(dustin)
Comment 3•10 years ago
|
||
Comment on attachment 8475225 [details] [diff] [review] bug1035898.patch No need for the extra license header, but otherwise looks good.
Attachment #8475225 -
Flags: review?(dustin) → review+
Updated•10 years ago
|
Attachment #8475225 -
Flags: checked-in+
Updated•10 years ago
|
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•