Skip to content

Commit

Permalink
(CDPE-6220) Fix variable references in run.pp
Browse files Browse the repository at this point in the history
Currently, CD4PE is using this module as part of the version 5
installation. When we use docker::run, we're getting warnings like this
in the customer-facing terminal output:

Unknown variable: 'docker::docker_group'. (file: /Users/eric.putnam/ws/cd4pe/PipelinesInfra/deploy/envs/cdpe6633/.modules/docker/manifests/run.pp, line: 268, column: 19)
Unknown variable: 'docker::service_name'. (file: /Users/eric.putnam/ws/cd4pe/PipelinesInfra/deploy/envs/cdpe6633/.modules/docker/manifests/run.pp, line: 267, column: 19)

This doesn't make for a very good customer experience. Since these vars
are in docker::params, I added "::params" to the two lines where
docker_group and service_name are assigned and that seemed to take care
of the warnings. Please correct me if I'm wrong about this change, our
main goal is to get rid of these warnings.
  • Loading branch information
eputnam committed Apr 18, 2024
1 parent 65e36c1 commit f811aa7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions manifests/run.pp
Original file line number Diff line number Diff line change
Expand Up @@ -264,8 +264,8 @@
$docker_command = $docker::params::docker_command
}

$service_name = $docker::service_name
$docker_group = $docker::docker_group
$service_name = $docker::params::service_name
$docker_group = $docker::params::docker_group

if $restart {
assert_type(Pattern[/^(no|always|unless-stopped|on-failure)|^on-failure:[\d]+$/], $restart)
Expand Down

0 comments on commit f811aa7

Please sign in to comment.