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

package_use does not remove entries #17

Closed
tampakrap opened this issue Dec 3, 2012 · 4 comments
Closed

package_use does not remove entries #17

tampakrap opened this issue Dec 3, 2012 · 4 comments

Comments

@tampakrap
Copy link

Steps to reproduce:

  1. Add a package_use entry:
package_use { "sys-process/htop":
  use => "unicode",
  target => "htop",
}
  1. Run puppet agent
  2. Remove the entry
  3. Run agent again

The entry is still there in /etc/portage/package.use/htop, while it should be removed. Ideally, if the file does not have any other entries, it should be removed as well.

@adrienthebo
Copy link

Nominally, you could be able to do this:

resources { 'package_use':
  purge => true,
}

And it would remove all unmanaged resources. The bad news with this is that unless the file is /etc/portage/package.*/default the ParsedFile provider can't purge it. The ParsedFile provider can't handle any resources with a non-default target. Resolving this will mean implementing a new provider for the package_* types.

@ghost ghost assigned adrienthebo Dec 3, 2012
@tampakrap
Copy link
Author

I've given it a thought and the solution above seems acceptable, so I'll close the issue

@adrienthebo
Copy link

The solution above reimplementing the providers, or the resources resource?

@tampakrap
Copy link
Author

the resources resource, that's why I closed the issue ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants