File manager - Edit - /home/u478019808/domains/bestandroidphones.store/public_html/static/img/logo/dispatcher.d.zip
Back
PK kv�Z:}�o o 20-chrony-dhcpnu ȯ�� #!/usr/bin/sh # This is a NetworkManager dispatcher script for chronyd to update # its NTP sources with servers from DHCP options passed by NetworkManager # in the DHCP4_NTP_SERVERS and DHCP6_DHCP6_NTP_SERVERS environment variables. export LC_ALL=C interface=$1 action=$2 [ -f /etc/sysconfig/network ] && . /etc/sysconfig/network [ -f /etc/sysconfig/network-scripts/ifcfg-"${interface}" ] && \ . /etc/sysconfig/network-scripts/ifcfg-"${interface}" chronyc=/usr/bin/chronyc server_options=${NTPSERVERARGS:-iburst} server_dir=/run/chrony-dhcp dhcp_server_file=$server_dir/$interface.sources dhcp_ntp_servers="$DHCP4_NTP_SERVERS $DHCP6_DHCP6_NTP_SERVERS" add_servers_from_dhcp() { rm -f "$dhcp_server_file" # Don't add NTP servers if PEERNTP=no specified; return early. [ "$PEERNTP" = "no" ] && return for server in $dhcp_ntp_servers; do # Check for invalid characters (from the DHCPv6 NTP FQDN suboption) len1=$(printf '%s' "$server" | wc -c) len2=$(printf '%s' "$server" | tr -d -c 'A-Za-z0-9:.-' | wc -c) if [ "$len1" -ne "$len2" ] || [ "$len2" -lt 1 ] || [ "$len2" -gt 255 ]; then continue fi printf 'server %s %s\n' "$server" "$server_options" >> "$dhcp_server_file" done $chronyc reload sources > /dev/null 2>&1 || : } clear_servers_from_dhcp() { if [ -f "$dhcp_server_file" ]; then rm -f "$dhcp_server_file" $chronyc reload sources > /dev/null 2>&1 || : fi } mkdir -p $server_dir case "$action" in up|dhcp4-change|dhcp6-change) add_servers_from_dhcp;; down) clear_servers_from_dhcp;; esac exit 0 PK kv�Z�Wߒ 20-chrony-onofflinenu ȯ�� #!/usr/bin/sh # This is a NetworkManager dispatcher / networkd-dispatcher script for # chronyd to set its NTP sources online or offline when a network interface # is configured or removed export LC_ALL=C chronyc=/usr/bin/chronyc # For NetworkManager consider only selected events if [ $# -ge 2 ]; then case "$2" in up|down|connectivity-change) ;; dhcp4-change|dhcp6-change) # Actions "up" and "connectivity-change" in some cases do not # guarantee that the interface has a route (e.g. a bond). # dhcp(x)-change handles at least cases that use DHCP. ;; *) exit 0;; esac fi # Note: for networkd-dispatcher routable.d ~= on and off.d ~= off $chronyc onoffline > /dev/null 2>&1 exit 0 PK kv�Z:}�o o 20-chrony-dhcpnu ȯ�� PK kv�Z�Wߒ � 20-chrony-onofflinenu ȯ�� PK �
| ver. 1.4 |
Github
|
.
| PHP 8.2.28 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings