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

Printers are created on every Puppet run #26

Closed
Socob opened this issue Oct 23, 2017 · 3 comments
Closed

Printers are created on every Puppet run #26

Socob opened this issue Oct 23, 2017 · 3 comments
Assignees

Comments

@Socob
Copy link

Socob commented Oct 23, 2017

I’m not sure if this is the same issue as #12 – there seem to be a lot of things in there which aren’t directly related to my problem.

Given Ubuntu 17.10 with Puppet Agent 4.10.4 and CUPS 2.2.4. I haven’t changed anything about the default CUPS configuration (e. g. cupsd.conf) that comes with Ubuntu 17.10.

When I apply the manifest

printers.pp

class { cups:
	default_queue => 'usbprint',
	papersize => a4,
}
cups_queue { 'usbprint':
	ensure => printer,
	uri => 'usb://Dell/Color%20MFP%20S2825cdn?serial=FH8080296&interface=1',
	model => 'lsb/usr/Dell/Dell_Color_MFP_S2825cdn.ppd.gz',
	enabled => true,
	accepting => true,
	shared => false,
}
cups_queue { 'netprint1':
	ensure => printer,
	uri => 'smb://print.example.com/netprint1',
	model => 'postscript-hp:0/ppd/hplip/HP/hp-laserjet_5100_series-ps.ppd',
	accepting => true,
}
cups_queue { 'netprint2':
	ensure => printer,
	uri => 'smb://print2.example.com/netprint2',
	model => 'drv:///hpcups.drv/hp-laserjet_p4014dn.ppd',
	accepting => true,
}

In order to set up local and network printers

Then I get the error message:

Not an error message, but each time I run puppet apply, the printers seem to be recreated:

# puppet apply printers.pp
Notice: Compiled catalog for pc.ad.example.com in environment production in 0.17 seconds
Notice: /Stage[main]/Main/Cups_queue[usbprint]/ensure: created a printer
Notice: /Stage[main]/Main/Cups_queue[netprint1]/ensure: created a printer
Notice: /Stage[main]/Main/Cups_queue[netprint2]/ensure: created a printer
Notice: Applied catalog in 1.23 seconds

Additional information:

  1. /usr/bin/ipptool is present
  2. Output of lpstat -t:
# lpstat -t
scheduler is running
system default destination: usbprint
device for netprint1: smb://print.example.com/netprint1
device for netprint2: smb://print2.example.com/netprint2
device for usbprint: usb://Dell/Color%20MFP%20S2825cdn?serial=FH8080296&interface=1
netprint1 accepting requests since Fri 20 Oct 2017 04:15:07 PM CEST
netprint2 accepting requests since Fri 20 Oct 2017 04:15:07 PM CEST
usbprint accepting requests since Sat 21 Oct 2017 11:47:29 AM CEST
printer netprint1 disabled since Fri 20 Oct 2017 04:15:07 PM CEST -
	reason unknown
printer netprint2 disabled since Fri 20 Oct 2017 04:15:07 PM CEST -
	reason unknown
printer usbprint is idle.  enabled since Sat 21 Oct 2017 11:47:29 AM CEST
  1. Using
# request.ipp
{
  OPERATION CUPS-Get-Printers
  GROUP operation
  ATTR charset attributes-charset utf-8
  ATTR language attributes-natural-language en
  STATUS successful-ok
  DISPLAY printer-name
}

the output of ipptool -c ipp://localhost/ request.ipp is

# ipptool -c ipp://localhost/ request.ipp
successful-ok

Setting shared => true on the printers did not have any effect.

@leoarnold
Copy link
Owner

leoarnold commented Oct 23, 2017

Looks more like a duplicate of #19 / #23. Can you try with master/HEAD ?

@leoarnold leoarnold self-assigned this Oct 23, 2017
@Socob
Copy link
Author

Socob commented Oct 23, 2017

With master/HEAD, everything seems to work correctly. Cheers!

@leoarnold
Copy link
Owner

I hope to publish 2.0.0 soon.

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

No branches or pull requests

2 participants