mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-10-14 20:18:39 +00:00
cli: support dummy connections
This commit is contained in:
parent
b42f780e04
commit
4db7890fae
|
@ -183,6 +183,7 @@ NmcOutputField nmc_fields_settings_names[] = {
|
||||||
SETTING_FIELD (NM_SETTING_MACVLAN_SETTING_NAME, nmc_fields_setting_macvlan + 1), /* 28 */
|
SETTING_FIELD (NM_SETTING_MACVLAN_SETTING_NAME, nmc_fields_setting_macvlan + 1), /* 28 */
|
||||||
SETTING_FIELD (NM_SETTING_VXLAN_SETTING_NAME, nmc_fields_setting_vxlan + 1), /* 29 */
|
SETTING_FIELD (NM_SETTING_VXLAN_SETTING_NAME, nmc_fields_setting_vxlan + 1), /* 29 */
|
||||||
SETTING_FIELD (NM_SETTING_PROXY_SETTING_NAME, nmc_fields_setting_proxy + 1), /* 30 */
|
SETTING_FIELD (NM_SETTING_PROXY_SETTING_NAME, nmc_fields_setting_proxy + 1), /* 30 */
|
||||||
|
SETTING_FIELD (NM_SETTING_DUMMY_SETTING_NAME, nmc_fields_setting_dummy + 1), /* 31 */
|
||||||
{NULL, NULL, 0, NULL, NULL, FALSE, FALSE, 0}
|
{NULL, NULL, 0, NULL, NULL, FALSE, FALSE, 0}
|
||||||
};
|
};
|
||||||
#define NMC_FIELDS_SETTINGS_NAMES_ALL_X NM_SETTING_CONNECTION_SETTING_NAME","\
|
#define NMC_FIELDS_SETTINGS_NAMES_ALL_X NM_SETTING_CONNECTION_SETTING_NAME","\
|
||||||
|
@ -477,6 +478,7 @@ usage_connection_add (void)
|
||||||
" [source-port-min <0-65535>]\n"
|
" [source-port-min <0-65535>]\n"
|
||||||
" [source-port-max <0-65535>]\n"
|
" [source-port-max <0-65535>]\n"
|
||||||
" [destination-port <0-65535>]\n\n"
|
" [destination-port <0-65535>]\n\n"
|
||||||
|
" dummy: \n\n"
|
||||||
" SLAVE_OPTIONS:\n"
|
" SLAVE_OPTIONS:\n"
|
||||||
" bridge: [priority <0-63>]\n"
|
" bridge: [priority <0-63>]\n"
|
||||||
" [path-cost <1-65535>]\n"
|
" [path-cost <1-65535>]\n"
|
||||||
|
@ -3071,6 +3073,13 @@ static const NameItem nmc_vxlan_settings [] = {
|
||||||
{ NULL, NULL, NULL, FALSE }
|
{ NULL, NULL, NULL, FALSE }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static const NameItem nmc_dummy_settings [] = {
|
||||||
|
{ NM_SETTING_CONNECTION_SETTING_NAME, NULL, NULL, TRUE },
|
||||||
|
{ NM_SETTING_DUMMY_SETTING_NAME, NULL, NULL, TRUE },
|
||||||
|
{ NM_SETTING_WIRED_SETTING_NAME, "ethernet", NULL, FALSE },
|
||||||
|
{ NULL, NULL, NULL, FALSE }
|
||||||
|
};
|
||||||
|
|
||||||
/* Available connection types */
|
/* Available connection types */
|
||||||
static const NameItem nmc_valid_connection_types[] = {
|
static const NameItem nmc_valid_connection_types[] = {
|
||||||
{ NM_SETTING_GENERIC_SETTING_NAME, NULL, nmc_generic_settings }, /* Needs to be first. */
|
{ NM_SETTING_GENERIC_SETTING_NAME, NULL, nmc_generic_settings }, /* Needs to be first. */
|
||||||
|
@ -3098,6 +3107,7 @@ static const NameItem nmc_valid_connection_types[] = {
|
||||||
{ NM_SETTING_MACSEC_SETTING_NAME, NULL, nmc_macsec_settings },
|
{ NM_SETTING_MACSEC_SETTING_NAME, NULL, nmc_macsec_settings },
|
||||||
{ NM_SETTING_MACVLAN_SETTING_NAME, NULL, nmc_macvlan_settings },
|
{ NM_SETTING_MACVLAN_SETTING_NAME, NULL, nmc_macvlan_settings },
|
||||||
{ NM_SETTING_VXLAN_SETTING_NAME, NULL, nmc_vxlan_settings },
|
{ NM_SETTING_VXLAN_SETTING_NAME, NULL, nmc_vxlan_settings },
|
||||||
|
{ NM_SETTING_DUMMY_SETTING_NAME, NULL, nmc_dummy_settings },
|
||||||
{ NULL, NULL, NULL }
|
{ NULL, NULL, NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -717,6 +717,13 @@ NmcOutputField nmc_fields_setting_dcb[] = {
|
||||||
NM_SETTING_DCB_PRIORITY_STRICT_BANDWIDTH","\
|
NM_SETTING_DCB_PRIORITY_STRICT_BANDWIDTH","\
|
||||||
NM_SETTING_DCB_PRIORITY_TRAFFIC_CLASS
|
NM_SETTING_DCB_PRIORITY_TRAFFIC_CLASS
|
||||||
|
|
||||||
|
/* Available fields for NM_SETTING_DUMMY_SETTING_NAME */
|
||||||
|
NmcOutputField nmc_fields_setting_dummy[] = {
|
||||||
|
SETTING_FIELD ("name"), /* 0 */
|
||||||
|
{NULL, NULL, 0, NULL, FALSE, FALSE, 0}
|
||||||
|
};
|
||||||
|
#define NMC_FIELDS_SETTING_DUMMY_ALL "name"
|
||||||
|
|
||||||
/* Available fields for NM_SETTING_TUN_SETTING_NAME */
|
/* Available fields for NM_SETTING_TUN_SETTING_NAME */
|
||||||
NmcOutputField nmc_fields_setting_tun[] = {
|
NmcOutputField nmc_fields_setting_tun[] = {
|
||||||
SETTING_FIELD ("name"), /* 0 */
|
SETTING_FIELD ("name"), /* 0 */
|
||||||
|
|
|
@ -95,5 +95,6 @@ extern NmcOutputField nmc_fields_setting_macvlan[];
|
||||||
extern NmcOutputField nmc_fields_setting_macsec[];
|
extern NmcOutputField nmc_fields_setting_macsec[];
|
||||||
extern NmcOutputField nmc_fields_setting_vxlan[];
|
extern NmcOutputField nmc_fields_setting_vxlan[];
|
||||||
extern NmcOutputField nmc_fields_setting_proxy[];
|
extern NmcOutputField nmc_fields_setting_proxy[];
|
||||||
|
extern NmcOutputField nmc_fields_setting_dummy[];
|
||||||
|
|
||||||
#endif /* NMC_SETTINGS_H */
|
#endif /* NMC_SETTINGS_H */
|
||||||
|
|
|
@ -1054,7 +1054,7 @@ init_if (GDBusInterface *interface, gpointer user_data)
|
||||||
|
|
||||||
props = g_dbus_proxy_get_cached_property_names (proxy);
|
props = g_dbus_proxy_get_cached_property_names (proxy);
|
||||||
|
|
||||||
for (prop = props; *prop; prop++) {
|
for (prop = props; prop && *prop; prop++) {
|
||||||
val = g_dbus_proxy_get_cached_property (proxy, *prop);
|
val = g_dbus_proxy_get_cached_property (proxy, *prop);
|
||||||
str = g_variant_print (val, TRUE);
|
str = g_variant_print (val, TRUE);
|
||||||
handle_property_changed (self, *prop, val);
|
handle_property_changed (self, *prop, val);
|
||||||
|
|
|
@ -925,6 +925,7 @@
|
||||||
<listitem><para><literal>ip-tunnel</literal></para></listitem>
|
<listitem><para><literal>ip-tunnel</literal></para></listitem>
|
||||||
<listitem><para><literal>macvlan</literal></para></listitem>
|
<listitem><para><literal>macvlan</literal></para></listitem>
|
||||||
<listitem><para><literal>vxlan</literal></para></listitem>
|
<listitem><para><literal>vxlan</literal></para></listitem>
|
||||||
|
<listitem><para><literal>dummy</literal></para></listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
|
|
||||||
<para>The most typical uses are described in the <link linkend='examples' endterm='examples.title' /> section.</para>
|
<para>The most typical uses are described in the <link linkend='examples' endterm='examples.title' /> section.</para>
|
||||||
|
|
Loading…
Reference in a new issue