Skip to content

Commit

Permalink
Fixing puppet-lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianSipos committed Apr 3, 2024
1 parent cdde86a commit a2a2acd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
4 changes: 2 additions & 2 deletions puppet/modules/anms/manifests/docker.pp
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
ensure => 'absent',
before => Package['docker-ce'],
}

}
default: {}
}

package { 'yum-utils':
Expand All @@ -20,7 +20,7 @@
ensure => 'absent',
}
exec { 'yum-repo-docker-ce':
path => $::path,
path => $facts['path'],
command => 'yum-config-manager --add-repo https://download.docker.com/linux/rhel/docker-ce.repo',
creates => '/etc/yum.repos.d/docker-ce.repo',
}
Expand Down
11 changes: 7 additions & 4 deletions puppet/modules/anms/manifests/docker_compose.pp
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,19 @@
case $ensure {
'present': {
exec { "docker-compose-${title}-up":
path => $::path,
command => "docker compose -p ${title} -f ${files_args} up --detach --remove-orphans ${up_args}",
path => $facts['path'],
command => "docker compose -p ${title} -f ${files_args} up --detach --remove-orphans ${up_args}",
}
}
'absent': {
exec { "docker-compose-${title}-up":
path => $::path,
path => $facts['path'],
command => "docker compose -p ${title} -f ${files_args} rm --force --stop",
onlyif => $is_running,
onlyif => $is_running,
}
}
default: {
fail("Invalid ensure argument: ${ensure}")
}
}
}

0 comments on commit a2a2acd

Please sign in to comment.