All Downloads are FREE. Search and download functionalities are using the official Maven repository.

[email protected] Maven / Gradle / Ivy

There is a newer version: 0.16.4
Show newest version
/*
 * Copyright (c) 2015 Brocade Communications Systems, Inc. and others.  All rights reserved.
 *
 * This program and the accompanying materials are made available under the
 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
 * and is available at http://www.eclipse.org/legal/epl-v10.html
 */
module neutron-subnets {

    yang-version 1;

    namespace "urn:opendaylight:neutron-subnets";

    prefix neutron-subnets;

    import ietf-yang-types { prefix "yang"; }
    import ietf-inet-types { prefix "inet"; revision-date 2013-07-15; }
    import neutron-attrs { prefix "attrs"; }
    import neutron-constants { prefix "constants"; }

    organization "OpenDaylight Neutron Group";

    contact "J. Gregory Hall , Kiran Sreenivasa ";

    description "This YANG module defines Openstack Neutron Subnets model";

    revision "2015-07-12" {
        description
                "OpenDaylight Beryllium release";
    }

    grouping subnet-attributes {
        leaf network-id {
            type yang:uuid;
            description "network this subnet is associated with.";
        }
        leaf ip-version {
            description "IP version";
            type identityref {
                base "constants:ip-version-base";
            }
        }
        leaf cidr {
            type inet:ip-prefix;
            description "cidr representing IP range for this subnet, based on IP version";
        }
        leaf gateway-ip {
            type inet:ip-address;
            description "default gateway used by devices in this subnet";
        }
        leaf-list dns-nameservers {
            type inet:ip-address;
            description "DNS name servers used by hosts in this subnet.";
            // neutron subnet-create test-net1 40.0.0.0/24 --dns-nameservers list=true 8.8.8.7 8.8.8.8        }        }
        }
        leaf ipv6-address-mode {

            description "neutron subnet-create --ip-version 6 --ipv6_ra_mode off --ipv6_address_mode
                        off NETWORK CIDR neutron subnet-create --ip-version 6 --ipv6_ra_mode
                        off --ipv6_address_mode dhcpv6-stateful NETWORK CIDR neutron subnet-create
                        --ip-version 6 --ipv6_ra_mode slaac --ipv6_address_mode slaac
                        NETWORK CIDR neutron subnet-create --ip-version 6 --ipv6_ra_mode
                        dhcpv6-stateful --ipv6_address_mode off NETWORK CIDR neutron subnet-create
                        --ip-version 6 --ipv6_ra_mode dhcpv6-stateless --ipv6_address_mode
                        dhcpv6-stateless NETWORK CIDR Note: can't find this in the spec
                        but OS is sending it with a null value.";
            type identityref {
                base "constants:dhcpv6-base";
            }
        }
        leaf ipv6-ra-mode {
            description "TODO can't find this in the spec but OS sends it with a null
                        value.";
            type identityref {
                base "constants:dhcpv6-base";
            }
        }
        list allocation-pools {
            description "Sub-ranges of cidr available for dynamic allocation to ports";
            key start;
            leaf start {
                type inet:ip-address;
            }
            leaf end {
                type inet:ip-address;
            }
        }
        list host-routes {
            description "Routes that should be used by devices with IPs from this subnet
                        (not including local subnet route).";
            key destination;
            leaf destination {
                description "Specifies a destination in CIDR format";
                type inet:ip-prefix;
            }
            leaf nexthop {
                type inet:ip-address;
            }
        }
        leaf enable-dhcp {
            type boolean;
            description "Specifies whether DHCP is enabled for this subnet or not.";
            default "true";
        }
    }
    grouping subnets-attributes {
        container subnets {
            list subnet {
                key "uuid";
                uses attrs:base-attributes;
                uses subnet-attributes;
            }
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy