Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate declaration: Package[git] with ensure_packages #29

Closed
philipfreude opened this issue Jul 6, 2020 · 2 comments
Closed

Duplicate declaration: Package[git] with ensure_packages #29

philipfreude opened this issue Jul 6, 2020 · 2 comments
Assignees
Labels

Comments

@philipfreude
Copy link
Contributor

Using ensure_packages('git') for puppetmaster setup creates a duplicate declaration error when the package 'git' is included in another module with something else than ensure_packages('git') or ensure => present.

A good explanation can be found in this issue for another module:
willdurand/puppet-composer#44

I propose changing the

ensure_packages('git')

to a

if !defined(Package['git']) {
      ensure_packages('git')
}

which will solve the issue.

@philipfreude
Copy link
Contributor Author

philipfreude commented Jul 6, 2020

see #30

@fraenki
Copy link
Member

fraenki commented Jul 7, 2020

Fix will be available in the upcoming 2.1.0.

@fraenki fraenki closed this as completed Jul 7, 2020
@fraenki fraenki self-assigned this Jul 7, 2020
@fraenki fraenki added the bug label Jul 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants