Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-10 Thread Ludovic Courtès
Andy Wingo skribis: > On Mon 10 Oct 2016 10:32, Clément Lassieur writes: > >>> +(define-record-type* >>> + configuration-field make-configuration-field configuration-field? >>> + (name configuration-field-name) >>> + (type configuration-field-type) >>> + (getter configuration-field-getter)

[PATCH 3/3] gnu: Add CUPS service.

2016-10-10 Thread Andy Wingo
CUPS printing service. To add printer support to a GuixSD +system, add a @code{cups-service} to the operating system definition: + +@deffn {Scheme Variable} cups-service-type +The service type for the CUPS print server. Its value should be a valid +CUPS configuration (see below). For example: +@ex

Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-10 Thread Andy Wingo
On Mon 10 Oct 2016 10:32, Clément Lassieur writes: >> +(define-record-type* >> + configuration-field make-configuration-field configuration-field? >> + (name configuration-field-name) >> + (type configuration-field-type) >> + (getter configuration-field-getter) >> + (predicate configuration

Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-10 Thread Clément Lassieur
> +(define-record-type* > + configuration-field make-configuration-field configuration-field? > + (name configuration-field-name) > + (type configuration-field-type) > + (getter configuration-field-getter) > + (predicate configuration-field-predicate) > + (serializer configuration-field-seri

Re: [PATCH] gnu: Add CUPS service.

2016-10-10 Thread Andy Wingo
a follow-up, but yeah, this procedure should eventually live elsewhere. > >> +(define* (cups-service #:key (config (cups-configuration))) >> + "Return a service that runs @var{cups}, the Cups database server. >> + >> +The Cups daemon loads its runtime co

Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-09 Thread Ricardo Wurmus
s it listens on, what to do if a print job > +fails, how much logging to do, and so on. To actually add a printer, > +you have to visit the @url{http://localhost:631} URL, or use a tool such > +as GNOME's printer configuration services. By default, configuring a > +CUPS ser

Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-09 Thread Christopher Allan Webber
Andy Wingo writes: > I'll commit in a couple days if no objections. > > Andy It sounds great. (Though I haven't spent any time reading through it.) I think a proper CUPS service is one of the big glaring ommissions from GuixSD; this would be a great feature to advertise in the next release.

Re: [PATCH 3/3] gnu: Add CUPS service.

2016-10-08 Thread Andy Wingo
name package) (service (service-type (name name) (extensions (list (service-extension cups-service-type identity package)) (operating-system ... (services (cons (make-cups-extension 'foomatic foomatic) ...)))

[PATCH 3/3] gnu: Add CUPS service.

2016-10-07 Thread Andy Wingo
CUPS printing service. To add printer support to a GuixSD +system, add a @code{cups-service} to the operating system definition: + +@deffn {Scheme Procedure} cups-service [#:config (cups-configuration)] +Return a service that runs the CUPS print server. +@end deffn + +The CUPS configuration controls the

Re: [PATCH] gnu: Add CUPS service.

2016-10-06 Thread Ludovic Courtès
uot;Failed to create public key at ~a.\n" public-key) > + (let ((user (getpwnam "cups"))) > +(mkdir-p/perms "/var/run/cups" user #o755) > +(mkdir-p/perms "/var/spool/cups" user #o755) > +(mkdir-p/perms "/var/log/c

Re: [PATCH] gnu: Add CUPS service.

2016-10-06 Thread Ludovic Courtès
Danny Milosavljevic skribis: >> + (define %cups-accounts >> + (list (user-group (name "cups") (system? #t)) >> +(user-account >> + (name "cups") >> + (group "cups") >> + (system? #t) >> + (comment "CUPS print server user") >> + (home-directory "/v

Re: [PATCH] gnu: Add CUPS service.

2016-10-05 Thread Danny Milosavljevic
Hi, nice! > + (define %cups-accounts > + (list (user-group (name "cups") (system? #t)) > +(user-account > + (name "cups") > + (group "cups") > + (system? #t) > + (comment "CUPS print server user") > + (home-directory "/var/empty") > + (sh

[PATCH] gnu: Add CUPS service.

2016-10-05 Thread Andy Wingo
CUPS printing service. To add printer support to a GuixSD +system, add a @code{cups-service} to the operating system definition: + +@deffn {Scheme Procedure} cups-service [#:config (cups-configuration)] +Return a service that runs the CUPS print server. +@end deffn + +The CUPS configuration control

Re: cups-service v2

2016-04-29 Thread Ludovic Courtès
Danny Milosavljevic skribis: > I think I have most of the parts now. Not sure how to tie them together, > though: [...] > +(define-module (gnu services printing) Overall the patch looks good, but did you have a chance to test it? (Sorry for the delay…) Thanks, Ludo’.

cups-service v2

2016-03-23 Thread Danny Milosavljevic
e (gnu services shepherd) + #:use-module (gnu packages cups) + #:use-module (guix gexp) + #:use-module (guix records) + #:use-module (srfi srfi-1) + #:use-module (srfi srfi-9) + #:use-module (srfi srfi-26) + #:use-module (ice-9 match) + #:export (cups-service)) + +(define (default-cups

Re: cups-service

2016-03-22 Thread Danny Milosavljevic
>ppds are usually in /usr/share/hplip Oops, I meant in /usr/share/ppd/hplip

cups-service

2016-03-22 Thread Danny Milosavljevic
I added a cups-service to actually enable printing eventually, see below. What it should do (and doesn't do yet) is union together several directories of other packages. The generated cups-files.conf should contain as "DataDir" (usually /usr/share) the data directory that c