Skip to content

Commit fdf4d93

Browse files
committed
debian/redhat: ship freeradius-utils-json package
New subpackage holding the three v3 JSON conversion utilities (radconf2json, radmod2json, raddict2json) for both Debian and RPM, mirroring the v4 freeradius-utils-json layout. Split out from the main freeradius-utils package because these binaries hard-link against json-c at runtime - users that only want radclient and friends shouldn't be forced to install json-c.
1 parent 252a8be commit fdf4d93

3 files changed

Lines changed: 41 additions & 0 deletions

File tree

debian/control.in

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,20 @@ Recommends: libtemplate-perl, libdbi-perl, libyaml-libyaml-perl, libdbd-pg-perl,
100100
Description: FreeRADIUS Perl utilities
101101
This package contains utilities for managing IP pools in SQL databases
102102

103+
Package: freeradius-utils-json
104+
Architecture: any
105+
Depends: ${shlibs:Depends}, ${misc:Depends}, ${dist:Depends}, freeradius-common, libfreeradius3 (= ${binary:Version})
106+
Description: FreeRADIUS JSON conversion utilities
107+
This package contains utilities that bridge between FreeRADIUS configuration
108+
and JSON:
109+
- radconf2json: render a parsed server configuration as JSON
110+
- radmod2json: dump the CONF_PARSER definitions of installed modules as JSON
111+
- raddict2json: dump the parsed dictionary tree as JSON
112+
.
113+
These utilities are intended for tooling that needs to inspect or transform
114+
FreeRADIUS configuration programmatically (config migration, schema
115+
documentation, third-party integrations).
116+
103117
Package: libfreeradius3
104118
Architecture: any
105119
Depends: ${shlibs:Depends}, ${misc:Depends}, ${dist:Depends}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
usr/bin/radconf2json
2+
usr/bin/radmod2json
3+
usr/bin/raddict2json

redhat/freeradius.spec

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,24 @@ Requires: perl-Net-IP
170170
This package provides Perl utilities for managing IP pools stored in
171171
SQL databases.
172172

173+
%package utils-json
174+
Summary: FreeRADIUS configuration <-> JSON conversion utilities
175+
Group: System Environment/Daemons
176+
Requires: %{name} = %{version}-%{release}
177+
Requires: json-c >= 0.10
178+
BuildRequires: json-c-devel >= 0.10
179+
180+
%description utils-json
181+
Utilities that bridge between FreeRADIUS configuration and JSON:
182+
183+
radconf2json render a parsed server configuration as JSON
184+
radmod2json dump the CONF_PARSER definitions of installed modules as JSON
185+
raddict2json dump the parsed dictionary tree as JSON
186+
187+
These utilities are intended for tooling that needs to inspect or
188+
transform FreeRADIUS configuration programmatically (config migration,
189+
schema documentation, third-party integrations).
190+
173191
%if %{!?_without_ldap:1}%{?_without_ldap:0}
174192
%package ldap
175193
Summary: LDAP support for FreeRADIUS
@@ -908,6 +926,12 @@ fi
908926
#man-pages
909927
%doc %{_mandir}/man8/rlm_sqlippool_tool.8.gz
910928

929+
%files utils-json
930+
%defattr(-,root,root)
931+
/usr/bin/radconf2json
932+
/usr/bin/radmod2json
933+
/usr/bin/raddict2json
934+
911935
%if %{?_with_rlm_cache_memcached:1}%{!?_with_rlm_cache_memcached:0}
912936
%files memcached
913937
%defattr(-,root,root)

0 commit comments

Comments
 (0)