Re: [chrony-dev] [PATCH] nm-dispatcher: handle NTP servers from DHCP

[ Thread Index | Date Index | More chrony.tuxfamily.org/chrony-dev Archives ]


On Thu, May 21, 2020 at 01:48:31PM -0400, Robert Fairley wrote:
> Would it be reasonable to check `os-release`, and source /etc/sysconfig
> if `ID`/`ID_LIKE` has `fedora` or `rhel`? Directories set by
> $chrony_conf, $chrony_service, and $helper_dir could be set in an
> environment file maintained downstream (with defaults to certain
> locations). Other than that, places where $PEERNTP and $NTPSERVERARGS
> are used which normally come from sysconfig could be left as-is, and
> have distributions set them to an empty value in the downstream
> environment file, or make their use conditional on the `os-release`check
> above.

I'd rather avoid having any distribution-specific code in the
examples. If there was a downstream change in one of the directories
for instance, we would need to support different versions of the
distribution.

If you would like to submit the chrony-helper script, please remove
the sysconfig/PEERNTP stuff. It can be put back in a downstream patch.
The various locations in the script can be set to strings like
@CHRONYC@, @CHRONYCONF@, @DHCP_SERVERS_FILES@ to indicate they need to
be edited before use.

Also, please rename the dhclient_servers_files variable to
dhcp_servers_file and remove the add/remove-dhclient-servers commands. 

The NM dispatcher script should follow the same idea, e.g. the check
of /sbin/dhclient should be in a downstream patch.

-- 
Miroslav Lichvar


-- 
To unsubscribe email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "unsubscribe" in the subject.
For help email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "help" in the subject.
Trouble?  Email listmaster@xxxxxxxxxxxxxxxxxxxx.


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/