Consfigurator 1.3.0 released
Sean Whitton
spwhitton at spwhitton.name
Fri Mar 17 18:10:18 GMT 2023
I am pleased to announce Consfigurator 1.3.0.
News since the last version announced to this list (1.1.0):
- Documentation (<https://spwhitton.name/doc/consfigurator>):
- New tutorial, "Defining new properties"
<https://spwhitton.name/doc/consfigurator/tutorial/properties.html>
- Extract docstrings and use them to generate API references in the
manual. It should now be possible to know what properties are
available for your use without having to read the source of
properties modules.
- New manual section "Reader macros" discussing Consfigurator's named
readtable, including some usage reservations for the sake of future
extension.
- Properties:
- APT:PROXY, LXC:USER-CONTAINER and LXC:USER-CONTAINER-FOR are now
unapplicable.
- Add FILE:CONTAINS-CONF-UNSPACED, LXC:USER-CONTAINER-STOPPED and
FILE:EMPTY-DIRECTORY-DOES-NOT-EXIST.
- APT properties now cache what packages have been explicitly
installed and removed this deployment. This should significantly
speed up many deployments.
- APT:INSTALLED, APT:INSTALLED-MINIMALLY and APT:REMOVED now only
execute apt-get(8). Previously they tried to determine whether the
packages were already installed or removed by parsing output from
apt-cache(8), but the implementation sometimes gave the wrong
answer.
- APT properties: add ``non-free-firmware`` section to generated
sources lists. On Debian bullseye and older this will cause apt
updates to emit harmless warnings.
- Fix a bug in FILE:SYMLINKED that meant that with at least GNU
ln(1), the property would fail to overwrite existing symbolic links
in some cases.
- Fix a bug in FILE:DOES-NOT-EXIST which meant that it did nothing if
only some of the files that should not exist needed to be deleted.
- When recovering from a failed debootstrap, instead of just
recursively deleting the target directory, we now call
EMPTY-REMOTE-DIRECTORY, to empty it, instead. This is better when
the target directory is a mount point.
- Readtable:
- New reader macros ``#~m//`` and ``#~s///`` for shell- and Perl-style
regular expression matching and replacement.
- New reader macro ``#>>EOF>>`` which is like ``#>EOF>`` except that
it skips over the remainder of the current line and its newline.
This is more like how heredocs work in other languages.
- Support for indented heredocs, where the indentation of the lines of
the heredoc is stripped. This mode is activated by prepending a
tilde to the heredoc terminator. For example:
(foo "argument 1" #>>~EOF>>
My line 1.
My line 2.
EOF)
The function receives ``"My line 1.\nMy line 2."``
This is a minor breaking change because heredoc terminators may no
longer begin with a tilde.
- Miscellaneous:
- New Emacs major mode, ``consfigurator-lisp-mode``. This takes care
of informing Emacs that parts of the buffer are CL-INTERPOL,
CL-HEREDOC and our ``#~m//`` and ``#~s///`` strings, fixing SLIME's
C-c C-c in certain cases.
- PROPAPPLY now signals an error if asked to apply a property that
has neither ``:APPLY`` nor ``:HOSTATTRS`` subroutines. This is
primarily intended to catch cases where the property is defined in
a ``.lisp`` file that you haven't yet added to your consfig's
``.asd`` file.
You can find the source at https://git.spwhitton.name/consfigurator for
browsing online or git cloning.
Releases are made by publishing signed git tags to that repository. The
tag for this release is named 'v1.3.0', and is signed by me.
On Debian/etc. systems, apt-get install cl-consfigurator/experimental
(In experimental due only to Debian being in a pre-release freeze.)
-8<-
Consfigurator is a system for declarative configuration management using
Common Lisp. You can use it to configure hosts as root, deploy services
as unprivileged users, build and deploy containers, install operating
systems, produce disc images, and more. Some key advantages:
* Apply configuration by transparently starting up another Lisp image
on the machine to be configured, so that you can use the full power
of Common Lisp to inspect and control the host.
* Also define properties of hosts in a more restricted language, that
of :POSIX properties, to configure machines, containers and user
accounts where you can't install Lisp. These properties can be
applied using just an SSH or serial connection, but they can also be
applied by remote Lisp images, enabling code reuse.
* Flexibly chain and nest methods of connecting to hosts. For example,
you could have Consfigurator SSH to a host, sudo to root, start up
Lisp, use the setns(2) system call to enter a Linux container, and
then deploy a service. Secrets, and other prerequisite data, are
properly passed along.
* Combine declarative semantics for defining hosts and services with a
multiparadigmatic general-purpose programming language that won't get
in your way.
Declarative configuration management systems like Consfigurator and
Propellor share a number of goals with projects like the GNU Guix System
and NixOS. However, tools like Consfigurator and Propellor try to layer
the power of declarative and reproducible configuration semantics on top
of traditional, battle-tested UNIX system administration infrastructure
like distro package managers, package archives and daemon configuration
mechanisms, rather than seeking to replace any of those. Let's get as
much as we can out of all that existing distro policy-compliant work!
--
Sean Whitton
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 869 bytes
Desc: not available
URL: <http://www.chiark.greenend.org.uk/pipermail/sgo-software-announce/attachments/20230317/4de3d991/attachment.sig>
More information about the sgo-software-announce
mailing list