]> git.ipfire.org Git - thirdparty/systemd.git/commit
resolvectl: add JSON output support for "resolvectl query"
authorLennart Poettering <lennart@poettering.net>
Wed, 31 Jan 2024 10:28:12 +0000 (11:28 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 31 Jan 2024 15:13:16 +0000 (16:13 +0100)
commit3557f1a62a487c0be080f2de866637a7895698c2
treeeb9cbd050524a6d2cc9e55b83e9a73f7aa3f1ac8
parent1d556e9e2a01e538ecddd8a2d8fb843391caf410
resolvectl: add JSON output support for "resolvectl query"

It's easy to add. Let's do so.

This only covers record lookups, i.e. with the --type= switch.

The higher level lookups are not covered, I opted instead to print a
message there to use --type= instead.

I am a bit reluctant to defining a new JSON format for the high-level
lookups, hence I figured for now a helpful error is good enough, that
points people to the right use.

Fixes: #29755
man/resolvectl.xml
src/resolve/resolvectl.c
test/units/testsuite-75.sh