File: SoftLayer_Network_Vlan.py

package info (click to toggle)
python-softlayer 6.1.4-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 5,100 kB
  • sloc: python: 53,771; makefile: 289; sh: 57
file content (59 lines) | stat: -rw-r--r-- 1,680 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
getObject = {
    'primaryRouter': {
        'datacenter': {'id': 1234, 'longName': 'TestDC'},
        'fullyQualifiedDomainName': 'fcr01.TestDC'
    },
    'id': 1234,
    'vlanNumber': 4444,
    'firewallInterfaces': None,
    'billingItem': {
        'allowCancellationFlag': 1,
        'categoryCode': 'network_vlan',
        'description': 'Private Network Vlan',
        'id': 235689,
        'notes': 'test cli',
        'orderItemId': 147258,
    },
    'subnets': [
        {
            'broadcastAddress': '169.46.22.127',
            'cidr': 28,
            'gateway': '169.46.22.113',
            'id': 1804813,
            'netmask': '255.255.255.240',
            'networkIdentifier': '169.46.22.112',
            'networkVlanId': 1404267,
            'subnetType': 'ADDITIONAL_PRIMARY',
            'totalIpAddresses': '16',
            'usableIpAddressCount': '13',
            'addressSpace': 'PUBLIC'
        },
        {
            'broadcastAddress': '150.239.7.191',
            'cidr': 27,
            'gateway': '150.239.7.161',
            'id': 2415982,
            'netmask': '255.255.255.224',
            'networkIdentifier': '150.239.7.160',
            'networkVlanId': 1404267,
            'subnetType': 'SECONDARY_ON_VLAN',
            'totalIpAddresses': '32',
            'usableIpAddressCount': '29',
            'version': 4,
            'addressSpace': 'PUBLIC'
        }],
    'hardware': [],
    'virtualGuests': [],
    'tagReferences': [],
}

editObject = True
setTags = True
getList = [getObject]

cancel = True

getCancelFailureReasons = [
    "1 bare metal server(s) still on the VLAN ",
    "1 virtual guest(s) still on the VLAN "
]