* Extending the mysql configuration
@ 2017-04-19 17:45 Christopher Baines
2017-04-20 9:07 ` Andy Wingo
0 siblings, 1 reply; 3+ messages in thread
From: Christopher Baines @ 2017-04-19 17:45 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1.1: Type: text/plain, Size: 949 bytes --]
Hey,
Does anyone have any advice about making the mysql service configuration
more flexible? At the moment, its not even possible to use a custom
configuration file without modifying the Guix source code.
My initial thoughts revolved around at some level providing access to a
data structure like:
(("mysqld" . (("datadir" . "/var/lib/mysql")
("socket" . "/var/run/mysql/mysql.sock")
("port" . "3306"))))
This could be part of a record, that can be built in to the
configuration file. This could also be a general feature, as I'm sure
other services will use this format, I spotted Avahi when looking
through the code.
I also spotted the define-configuration syntax, which looks like it
might work well, but I wanted to check if this was definitely a
direction more services were heading before attempting to write out a
large part of the supported configuration options.
Thanks,
Chris
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 858 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Extending the mysql configuration
2017-04-19 17:45 Extending the mysql configuration Christopher Baines
@ 2017-04-20 9:07 ` Andy Wingo
2017-04-21 21:53 ` Ludovic Courtès
0 siblings, 1 reply; 3+ messages in thread
From: Andy Wingo @ 2017-04-20 9:07 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Wed 19 Apr 2017 19:45, Christopher Baines <mail@cbaines.net> writes:
> I also spotted the define-configuration syntax, which looks like it
> might work well, but I wanted to check if this was definitely a
> direction more services were heading before attempting to write out a
> large part of the supported configuration options.
MHO is this is the direction we should go in. Having a configuration
defined in a data type that Guix can understand makes it easier to
operate on the system as a whole -- the system can see your mysql
configuration and introspect on it, it's easy to define extension
points, etc. There are a few services that use this approach and I
expect the number to grow over time. At the same time many of these
services have the option to fall back on an opaque configuration when
you have special needs or a different workflow -- see dovecot for a very
long example.
Andy
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Extending the mysql configuration
2017-04-20 9:07 ` Andy Wingo
@ 2017-04-21 21:53 ` Ludovic Courtès
0 siblings, 0 replies; 3+ messages in thread
From: Ludovic Courtès @ 2017-04-21 21:53 UTC (permalink / raw)
To: Andy Wingo; +Cc: guix-devel
Andy Wingo <wingo@igalia.com> skribis:
> On Wed 19 Apr 2017 19:45, Christopher Baines <mail@cbaines.net> writes:
>
>> I also spotted the define-configuration syntax, which looks like it
>> might work well, but I wanted to check if this was definitely a
>> direction more services were heading before attempting to write out a
>> large part of the supported configuration options.
>
> MHO is this is the direction we should go in. Having a configuration
> defined in a data type that Guix can understand makes it easier to
> operate on the system as a whole -- the system can see your mysql
> configuration and introspect on it, it's easy to define extension
> points, etc. There are a few services that use this approach and I
> expect the number to grow over time. At the same time many of these
> services have the option to fall back on an opaque configuration when
> you have special needs or a different workflow -- see dovecot for a very
> long example.
I agree.
Record types defined with ‘define-configuration’ or similar are
preferable to using an alist or another dictionary type also because of
the set of fields is checked at macro-expansion time (eventually I’d
like to have some static type checks in there too).
Ludo’.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-04-21 21:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-19 17:45 Extending the mysql configuration Christopher Baines
2017-04-20 9:07 ` Andy Wingo
2017-04-21 21:53 ` Ludovic Courtès
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).