diff --git a/doc/interfaces.scd b/doc/interfaces.scd index 318c71f..532d26d 100644 --- a/doc/interfaces.scd +++ b/doc/interfaces.scd @@ -70,10 +70,12 @@ the system will only respond to certain keywords by default: is for backwards compatibility and should not be used in new deployments. -*pointopoint* - Sets the given IPv4 address as the peer address on the interface. - This setting only takes effect for the IPv4 address familiy and - only makes sense in combination with as /32 netmask. +*point-to-point* _address_ + Sets the given IPv4 _address_ as the peer address on the + interface. This setting only takes effect for the IPv4 address + familiy and only makes sense in combination with a /32 netmask. + For compatiblity with ifupdown and ifupdown2, _pointopoint_ is + an alias for this parameter. *link-type* _link-type_ Denotes the link-type of the interface. When set to _dummy_, diff --git a/executor-scripts/linux/static b/executor-scripts/linux/static index 81f77ec..cb9af18 100755 --- a/executor-scripts/linux/static +++ b/executor-scripts/linux/static @@ -22,8 +22,8 @@ addr_family() { configure_addresses() { for i in $(ifquery -p address -i $INTERFACES_FILE $IFACE); do addrfam=$(addr_family $i) - if [ "${IF_POINTOPOINT}" -a "${addrfam}" = "-4" ]; then - PEER="peer ${IF_POINTOPOINT}" + if [ "${IF_POINT_TO_POINT}" -a "${addrfam}" = "-4" ]; then + PEER="peer ${IF_POINT_TO_POINT}" else PEER="" fi diff --git a/libifupdown/interface-file.c b/libifupdown/interface-file.c index fbaaa96..9783cda 100644 --- a/libifupdown/interface-file.c +++ b/libifupdown/interface-file.c @@ -79,6 +79,7 @@ static const struct remap_token tokens[] = { {"offload-tso", "ethtool-offload-tso"}, /* Debian ethtool integration */ {"offload-tx", "ethtool-offload-tx"}, /* Debian ethtool integration */ {"offload-ufo", "ethtool-offload-ufo"}, /* Debian ethtool integration */ + {"pointopoint", "point-to-point"}, /* legacy ifupdown, ifupdown2 */ {"provider", "ppp-provider"}, /* legacy ifupdown, ifupdown2 */ {"rx-offload", "ethtool-offload-rx"}, /* ifupdown2 */ {"tso-offload", "ethtool-offload-tso"}, /* ifupdown2 */ diff --git a/tests/linux/static_test b/tests/linux/static_test index b02915e..04c1a85 100755 --- a/tests/linux/static_test +++ b/tests/linux/static_test @@ -25,7 +25,7 @@ up_body() { up_ptp_body() { export IFACE=eth0 PHASE=up MOCK=echo INTERFACES_FILE="$FIXTURES/static-eth0-ptp.interfaces" \ - IF_POINTOPOINT="192.0.2.1" + IF_POINT_TO_POINT="192.0.2.1" atf_check -s exit:0 \ -o match:'addr add 203.0.113.2/32 peer 192.0.2.1 dev eth0' \ -o match:'route add default via 192.0.2.1 metric 1 dev eth0' \