# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('vns-interface-config')
command.model_obj_type_disable_submode('vns-access-list-entry')

command.model_obj_type_disable_submode('vns-interface-rule-network-service-node-mapping')

command.model_obj_type_disable_edit('vns-definition', 'description')
command.model_obj_type_disable_edit('vns-definition', 'origin')
command.model_obj_type_disable_edit('vns-definition', 'priority')
command.model_obj_type_disable_edit('vns-definition', 'vnsname')
command.model_obj_type_disable_edit('vns-definition', 'tenant')


command.model_obj_type_disable_edit('vns-access-list', 'priority')
command.model_obj_type_disable_edit('vns-access-list', 'description')

command.model_obj_type_set_show_this('vns-access-list', [
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode("flow-entry")

command.model_obj_type_enable_cascade_delete("flow-entry")

command.model_obj_type_disable_edit("flow-entry", "hard-timeout")
command.model_obj_type_disable_edit("flow-entry", "idle-timeout")
command.model_obj_type_disable_edit("flow-entry", "actions")
command.model_obj_type_disable_edit("flow-entry", "active")
command.model_obj_type_disable_edit("flow-entry", "priority")
command.model_obj_type_disable_edit("flow-entry", "cookie")
command.model_obj_type_disable_edit("flow-entry", "wildcards")
command.model_obj_type_disable_edit("flow-entry", "ingress-port")
command.model_obj_type_disable_edit("flow-entry", "src-mac")
command.model_obj_type_disable_edit("flow-entry", "dst-mac")
command.model_obj_type_disable_edit("flow-entry", "vlan-id")
command.model_obj_type_disable_edit("flow-entry", "vlan-priority")
Example #3
0
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_enable_cascade_delete('controller-node')
command.model_obj_type_enable_cascade_delete('controller-interface')
command.model_obj_type_enable_cascade_delete('controller-domain-name-server')
command.model_obj_type_enable_cascade_delete('controller-alias')
command.model_obj_type_enable_cascade_delete('firewall-rule')

command.model_obj_type_disable_submode('controller-node')
command.model_obj_type_disable_submode('controller-interface')
command.model_obj_type_disable_submode('controller-domain-name-server')
command.model_obj_type_disable_submode('controller-alias')
command.model_obj_type_disable_submode('firewall-rule')

command.model_obj_type_disable_edit('controller-node', 'domain-lookups-enabled')
command.model_obj_type_disable_edit('controller-node', 'domain-name')
command.model_obj_type_disable_edit('controller-node', 'default-gateway')
command.model_obj_type_disable_edit('controller-node', 'ntp-server')
command.model_obj_type_disable_edit('controller-node', 'time-zone')
command.model_obj_type_disable_edit('controller-node', 'logging-enabled')
command.model_obj_type_disable_edit('controller-node', 'logging-server')
command.model_obj_type_disable_edit('controller-node', 'logging-level')

command.model_obj_type_disable_edit('controller-interface', 'type')
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('snmp-server-config')
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('host-security-ip-address')
command.model_obj_type_disable_submode('host-security-attachment-point')

command.model_obj_type_disable_edit('host', 'last-seen')

command.model_obj_type_set_case('host', 'mac', 'lower')
command.model_obj_type_set_case('host-config', 'mac', 'lower')

command.model_obj_type_enable_cascade_delete('host-config')
command.model_obj_type_enable_cascade_delete('host-alias')
command.model_obj_type_enable_cascade_delete('host-security-ip-address')
command.model_obj_type_enable_cascade_delete('host-security-attachment-point')

command.model_obj_type_disable_edit('host-config', 'vlan')
command.model_obj_type_disable_edit('host-config', 'last-seen')
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('tech-support-config')
command.model_obj_type_disable_submode('image-drop-user')
command.model_obj_type_disable_submode('vlan-config')

command.model_obj_type_disable_edit('tag', 'name')
command.model_obj_type_disable_edit('tag', 'namespace')
command.model_obj_type_disable_edit('tag', 'value')
command.model_obj_type_disable_edit('tag', 'persist')

# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_enable_cascade_delete("controller-node")
command.model_obj_type_enable_cascade_delete("controller-interface")
command.model_obj_type_enable_cascade_delete("controller-domain-name-server")
command.model_obj_type_enable_cascade_delete("controller-alias")
command.model_obj_type_enable_cascade_delete("firewall-rule")

command.model_obj_type_disable_submode("controller-node")
command.model_obj_type_disable_submode("controller-interface")
command.model_obj_type_disable_submode("controller-domain-name-server")
command.model_obj_type_disable_submode("controller-alias")
command.model_obj_type_disable_submode("firewall-rule")

command.model_obj_type_disable_edit("controller-node", "domain-lookups-enabled")
command.model_obj_type_disable_edit("controller-node", "domain-name")
command.model_obj_type_disable_edit("controller-node", "default-gateway")
command.model_obj_type_disable_edit("controller-node", "ntp-server")
command.model_obj_type_disable_edit("controller-node", "time-zone")
command.model_obj_type_disable_edit("controller-node", "logging-enabled")
command.model_obj_type_disable_edit("controller-node", "logging-server")
command.model_obj_type_disable_edit("controller-node", "logging-level")

command.model_obj_type_disable_edit("controller-interface", "type")
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_enable_cascade_delete('address-space')
command.model_obj_type_enable_cascade_delete('address-space-identifier-rule')

command.model_obj_type_disable_submode('address-space')
command.model_obj_type_disable_submode('address-space-identifier-rule')

command.model_obj_type_disable_edit('address-space', 'active')
command.model_obj_type_disable_edit('address-space', 'description')
command.model_obj_type_disable_edit('address-space', 'priority')
command.model_obj_type_disable_edit('address-space', 'vlan-tag-on-egress')
command.model_obj_type_disable_edit('address-space', 'origin')

command.model_obj_type_disable_edit('address-space-identifier-rule', 'rule')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'active')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'ports')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'mac')
command.model_obj_type_disable_edit('address-space-identifier-rule',
                                    'priority')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'switch')
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('vns-interface-config')
command.model_obj_type_disable_submode('vns-access-list-entry')

command.model_obj_type_disable_submode(
    'vns-interface-rule-network-service-node-mapping')

command.model_obj_type_disable_edit('vns-definition', 'description')
command.model_obj_type_disable_edit('vns-definition', 'origin')
command.model_obj_type_disable_edit('vns-definition', 'priority')
command.model_obj_type_disable_edit('vns-definition', 'vnsname')
command.model_obj_type_disable_edit('vns-definition', 'tenant')

command.model_obj_type_disable_edit('vns-access-list', 'priority')
command.model_obj_type_disable_edit('vns-access-list', 'description')

command.model_obj_type_set_show_this('vns-access-list', [
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('tacacs-plus-config')
command.model_obj_type_disable_submode('tacacs-plus-host')

command.model_obj_type_disable_edit('tacacs-plus-config', 'tacacs-plus-authn')
command.model_obj_type_disable_edit('tacacs-plus-config', 'tacacs-plus-authz')
command.model_obj_type_disable_edit('tacacs-plus-config', 'tacacs-plus-acct')
command.model_obj_type_disable_edit('tacacs-plus-config', 'local-authn')
command.model_obj_type_disable_edit('tacacs-plus-config', 'local-authz')
command.model_obj_type_disable_edit('tacacs-plus-config', 'timeout')
command.model_obj_type_disable_edit('tacacs-plus-config', 'key')

command.model_obj_type_disable_edit('tacacs-plus-host', 'ip')
command.model_obj_type_disable_edit('tacacs-plus-host', 'key')
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode("snmp-server-config")
Example #12
0
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('topology-config')
Example #13
0
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_edit('switch-config', 'tunnel-termination')
command.model_obj_type_disable_edit('switch-config', 'core-switch')
command.model_obj_type_disable_edit('switch-config', 'dpid')

command.model_obj_type_disable_submode('switch')

command.model_obj_type_set_case('switch', 'dpid', 'lower')
command.model_obj_type_set_case('switch-config', 'dpid', 'lower')

command.model_obj_type_set_case('switch-interface-config', 'name', 'lower')

# rest-to-model model-like results from the switches/devices rest api
command.model_obj_type_set_case('switches', 'id', 'lower')
command.model_obj_type_set_case('switches', 'dpid', 'lower')

command.model_obj_type_set_case('interfaces', 'id', 'lower')
command.model_obj_type_set_case('interfaces', 'name', 'lower')
Example #14
0
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command 

command.model_obj_type_disable_submode('flow-entry')

command.model_obj_type_enable_cascade_delete('flow-entry')

command.model_obj_type_disable_edit('flow-entry', 'hard-timeout')
command.model_obj_type_disable_edit('flow-entry', 'idle-timeout')
command.model_obj_type_disable_edit('flow-entry', 'actions')
command.model_obj_type_disable_edit('flow-entry', 'active')
command.model_obj_type_disable_edit('flow-entry', 'priority')
command.model_obj_type_disable_edit('flow-entry', 'cookie')
command.model_obj_type_disable_edit('flow-entry', 'wildcards')
command.model_obj_type_disable_edit('flow-entry', 'ingress-port')
command.model_obj_type_disable_edit('flow-entry', 'src-mac')
command.model_obj_type_disable_edit('flow-entry', 'dst-mac')
command.model_obj_type_disable_edit('flow-entry', 'vlan-id')
command.model_obj_type_disable_edit('flow-entry', 'vlan-priority')
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_edit('switch-config', 'tunnel-termination')
command.model_obj_type_disable_edit('switch-config', 'core-switch')
command.model_obj_type_disable_edit('switch-config', 'dpid')

command.model_obj_type_disable_submode('switch')

command.model_obj_type_set_case('switch',        'dpid', 'lower')
command.model_obj_type_set_case('switch-config', 'dpid', 'lower')

command.model_obj_type_set_case('switch-interface-config', 'name', 'lower')



# rest-to-model model-like results from the switches/devices rest api
command.model_obj_type_set_case('switches',   'id', 'lower')
command.model_obj_type_set_case('switches',   'dpid', 'lower')

command.model_obj_type_set_case('interfaces', 'id', 'lower')
command.model_obj_type_set_case('interfaces', 'name', 'lower')
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_enable_cascade_delete('address-space')
command.model_obj_type_enable_cascade_delete('address-space-identifier-rule')

command.model_obj_type_disable_submode('address-space')
command.model_obj_type_disable_submode('address-space-identifier-rule')

command.model_obj_type_disable_edit('address-space', 'active')
command.model_obj_type_disable_edit('address-space', 'description')
command.model_obj_type_disable_edit('address-space', 'priority')
command.model_obj_type_disable_edit('address-space', 'vlan-tag-on-egress')
command.model_obj_type_disable_edit('address-space', 'origin')

command.model_obj_type_disable_edit('address-space-identifier-rule', 'rule')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'active')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'ports')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'mac')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'priority')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'switch')
command.model_obj_type_disable_edit('address-space-identifier-rule', 'tag')
#!/usr/bin/env python
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

# CLI for forwarding configuration
#

# --------------------------------------------------------------------------------
# Disable direct access to forwarding-config, use the new CLI instead
#

import command
command.model_obj_type_disable_submode('forwarding-config')

# --------------------------------------------------------------------------------
#
# Copyright (c) 2013 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance with the
# License. You may obtain a copy of the License at
#
#      http://www.eclipse.org/legal/epl-v10.html
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command

command.model_obj_type_disable_submode('tech-support-config')

Example #19
0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied. See the License for the specific language governing
# permissions and limitations under the License.
#

import command
command.model_obj_type_enable_cascade_delete('tenant')
command.model_obj_type_enable_cascade_delete('virtualrouter')
command.model_obj_type_weak_with_cascade_delete('virtualrouter-interface')
command.model_obj_type_weak_with_cascade_delete('virtualrouter-routingrule')
command.model_obj_type_enable_cascade_delete('interface-address-pool')
command.model_obj_type_weak_with_cascade_delete('virtualrouter-gwpool')
command.model_obj_type_enable_cascade_delete('gateway-address-pool')

command.model_obj_type_disable_submode('virtualrouter')
command.model_obj_type_disable_submode('virtualrouter-interface')
command.model_obj_type_disable_submode('virtualrouter-gwpool')
command.model_obj_type_disable_submode('virtualrouter-routingrule')
command.model_obj_type_disable_submode('interface-address-pool')
command.model_obj_type_disable_submode('gateway-address-pool')
command.model_obj_type_disable_submode('static-arp')
command.model_obj_type_disable_submode('tenant')

command.model_obj_type_disable_edit('tenant', 'active')
command.model_obj_type_disable_edit('tenant', 'description')
command.model_obj_type_disable_edit('tenant', 'origin')