Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Issue with wget ensure => installed #43

Closed
den-is opened this issue Jan 12, 2017 · 2 comments
Closed

Issue with wget ensure => installed #43

den-is opened this issue Jan 12, 2017 · 2 comments
Assignees
Labels
Milestone

Comments

@den-is
Copy link

den-is commented Jan 12, 2017

In my case there is issue with

  ensure_packages(['wget'], {
    ensure => installed,
})

Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Evaluation Error: Error while evaluating a Function Call, Duplicate declaration: Package[wget] is already declared in file /etc/puppetlabs/code/environments/development/modules/sysadmin/manifests/base.pp:2; cannot redeclare at /etc/puppetlabs/code/environments/development/modules/composer/manifests/init.pp:53 at /etc/puppetlabs/code/environments/development/modules/composer/manifests/init.pp:53:3

i'm controlling what software is installed on my nodes.
If there is need in some basic packages i'm using my own sysadmin::base which has couple packages like git, wget, vim, rsync, ...
Installing them with ensure_packages($packages_list)
and it not interferes with modules which have explicit packages install for example ensure_packages(['git']) or 'wget'.

In your case I don't understand why you have to use ensure_packages() with ensure => installed
do it like so if you want

package{ 'wget':
  ensure => installed,
}

But of course i'm here to suggest you to use simple form ensure_packages(['wget'])

Probably you will agree with me that it looks like nonsense: many puppet users have wget installation in their own modules/manifests and why they should be distracted with some module from forge which is not directly related to wget. Users which are using puppet should be smart enough to fix wget package on their systems, and use ensure_packages() for some trivial cases in manifests

@Ma27
Copy link
Collaborator

Ma27 commented Jan 12, 2017

have a look at #44, I wrote down a proposal for that (which includes your suggestion to revert this)

@Ma27 Ma27 closed this as completed in 2b24c10 Jan 12, 2017
@Ma27 Ma27 self-assigned this Jan 12, 2017
@Ma27 Ma27 added the bug label Jan 12, 2017
@Ma27 Ma27 added this to the 1.2.4 milestone Jan 12, 2017
@Ma27
Copy link
Collaborator

Ma27 commented Jan 12, 2017

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

No branches or pull requests

2 participants