summaryrefslogtreecommitdiff
path: root/support/dktools/printqd.conf.sample
blob: 136ba3f345f3b34ecb4425f597f680056bff4c6b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
# The options section contains general options.
# =============================================

[options]

# After startup the printqd process gives up privileges and runs
# under an unprivileged user account.
# Use the same UID ase the LPRng lpd daemon does.
# For some name services you can not use this option as only the
# root user has access to user and group information.
# --------------------------------------------------------------
# run as user		=	lp

# After startup the printqd process gives up privileges and runs
# under an unprivileged group.
# The group must have the following permissions:
# - Write access to the directory containing the local UNIX
#   domain socket,
# - Read/write access to the local UNIX domain socket, if it
#   already exists,
# - Write access to the log file (write access to the directory
#   containing the log file if the file does not yet exist) and
# - Write access to the database file(s) (write access to the
#   directory containing the database files if they do not
#   yet exist).
# Use the same GID as the LPRng lpd daemon does.
# --------------------------------------------------------------
# run as group		=	lp

# Database type and file name separated by `::', optional.
# By default the database is placed in the ${localstatedir}/printqd
# directory as file(s) printqd.* , the best available database type
# is choosen with a corresponding file name suffix.
# -----------------------------------------------------------------
# database		=	mem::/var/printqd/printqd.db

# Local UNIX domain socket, optional.
# Default is ${localstatedir}/run/printqd/printqd.sock .
# ------------------------------------------------------
# local socket		=	/var/run/printqd/printqd.sock

# Owner of the local socket.
# Only needed if ``run as user'' is not specified.
# Use the account of the LPRng print system.
# ------------------------------------------------
# local socket owner	=	lp

# Owner group of local socket.
# Only needed if ``run as group'' is not specified.
# Use the group of the LPRng print system.
# -------------------------------------------------
# local socket group	=	lp

# Number of connection attempts to queue for local UNIX domain socket.
# The default is 5. You should use at least 1 + number of print queues.
# ---------------------------------------------------------------------
# local socket backlog	=	5

# Maximum number of connections established over local UNIX domain socket.
# Should be at least 1 + number of print queues.
# ------------------------------------------------------------------------
# max local connections	=	7

# UDP port to receive info requests and send responses (optional).
# ----------------------------------------------------------------
# udp port		=	9100

# TCP port to listen for connections (optional).
# ----------------------------------------------
# tcp port		=	9100

# Number of connection attempts to queue for TCP port. Default: 5.
# ----------------------------------------------------------------
# tcp port backlog	=	5

# Maximum number of connections established over TCP port.
# --------------------------------------------------------
# max tcp connections	=	50

# The hosts below are allowed to send info requests.
# May be used multiple times.
# If no ``info allow'' line is present, access is denied
# from all hosts.
# The asterisk line would enable info requests from everywhere,
# this is only recommended if your network is behind a firewall
# or router with ACLs restricting inbound traffic.
# -------------------------------------------------------------
info allow		=	192.0.2.0/24
# info allow		=	*

# The host below is allowed to send data level requests.
# May be used multiple times.
# If no ``data allow'' line is present, access is denied
# from all hosts.
# ------------------------------------------------------
# data allow		=	127.0.0.1/32

# The hosts below are allowed to send admin level requests.
# In the example here we deny admin level requests over network.
# If no ``admin allow'' line is present, access is denied
# from all hosts.
# --------------------------------------------------------------
# admin allow		=	127.0.0.1/32

# Log file name, optional.
# Default is ${localstatedir}/log/printqd/printqdlog .
# ----------------------------------------------------
# log file		=	/var/log/printqd/printqd.log

# By default only minimum log is written.
# You can configure additional features in a comma separated list:
# - db		Write log entries for database changes.
# - info	Write log entries for info requests and responses.
# Use the shortcut ``*'' or ``all'' for maximum logging,
# ``-'' or ``none'' for minimum.
# ----------------------------------------------------------------
# log features		=	-


# A class is a group of printers. In the example below we assume
# two computer class rooms with printers lp and lp2.
# The limit configured for the class is the summary of pages on
# all printers in a class.
# ==============================================================

[class cl-mfd]

# Limits for specific users. Instead of the text ``unlimited''
# we could specify page numbers or the text ``denied''.
# The right side consists of user name and limit.
# ------------------------------------------------------------
user limit		=	Administrator	unlimited
user limit		=	Administ	unlimited
user limit		=	admin		unlimited
user limit		=	root		unlimited

# Group limits are used for those users without a user-specific
# limit.
# The right side consists of group name and limit.
# -------------------------------------------------------------
group limit		=	fac_m		unlimited

# The default limit is used for all users without user- or
# group-specific limit.
# The right side just contains the limit.
# --------------------------------------------------------
default limit		=	0

# The deny action decides wether a denied print job is
# removed (``remove'') or kept in the queue (``hold'').
# -----------------------------------------------------
deny action		=	remove


# There are two further printer classes.
# ======================================

[class cl-color]
user limit		=	Administrator	unlimited
user limit		=	Administ	unlimited
user limit		=	admin		unlimited
user limit		=	root		unlimited
group limit		=	fac_m		unlimited
default limit		=	0
deny action		=	remove

[class cl-lab]
user limit		=	Administrator	unlimited
user limit		=	Administ	unlimited
user limit		=	admin		unlimited
user limit		=	root		unlimited
group limit		=	fac_m		unlimited
default limit		=	200
deny action		=	remove


# Each printer must be a member of one of the classes configured above.
# =====================================================================

[printer lp1]

# The printer lp1 has an alias lp configured in the printcap file.
# ----------------------------------------------------------------
alias			=	lp

# The printer is a member of the cl-lab class.
# --------------------------------------------
class			=	cl-lab



# The printer in the other computer classroom is also in the cl-lab class.
# ========================================================================

[printer lp2]
class			=	cl-lab

# And the remaining printers
# ==========================

[printer lpcolor]
class			=	cl-color

[printer mfd]
class			=	cl-mfd