|
| 1 | +"""Set the Environment Information Needed to Access Your Lab! |
| 2 | +
|
| 3 | +The provided sample code in this repository will reference this file to get the |
| 4 | +information needed to connect to your lab backend. You provide this info here |
| 5 | +once and the scripts in this repository will access it as needed by the lab. |
| 6 | +
|
| 7 | +
|
| 8 | +Copyright (c) 2018-2022 Cisco and/or its affiliates. |
| 9 | +
|
| 10 | +Permission is hereby granted, free of charge, to any person obtaining a copy |
| 11 | +of this software and associated documentation files (the "Software"), to deal |
| 12 | +in the Software without restriction, including without limitation the rights |
| 13 | +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
| 14 | +copies of the Software, and to permit persons to whom the Software is |
| 15 | +furnished to do so, subject to the following conditions: |
| 16 | +
|
| 17 | +The above copyright notice and this permission notice shall be included in all |
| 18 | +copies or substantial portions of the Software. |
| 19 | +
|
| 20 | +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 21 | +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 22 | +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
| 23 | +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 24 | +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
| 25 | +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
| 26 | +SOFTWARE. |
| 27 | +""" |
| 28 | + |
| 29 | + |
| 30 | +# User Input |
| 31 | + |
| 32 | +# Please select the lab environment that you will be using today |
| 33 | +# sandbox - Cisco DevNet Always-On / Reserved Sandboxes |
| 34 | +# express - Cisco DevNet Express Lab Backend |
| 35 | +# custom - Your Own "Custom" Lab Backend |
| 36 | +ENVIRONMENT_IN_USE = "sandbox" |
| 37 | + |
| 38 | +# Custom Lab Backend |
| 39 | +DNA_CENTER = { |
| 40 | + "host": "", |
| 41 | + "username": "", |
| 42 | + "password": "" |
| 43 | +} |
| 44 | + |
| 45 | +# End User Input |
| 46 | + |
| 47 | + |
| 48 | +# Set the 'Environment Variables' based on the lab environment in use |
| 49 | +if ENVIRONMENT_IN_USE == "sandbox": |
| 50 | + DNA_CENTER = { |
| 51 | + "host": "sandboxdnac.cisco.com", |
| 52 | + "username": "devnetuser", |
| 53 | + "password": "Cisco123!" |
| 54 | + } |
| 55 | + |
| 56 | + # Values for the Always On IOS XE Sandbox |
| 57 | + IOS_XE_1 = { |
| 58 | + "host": "sandbox-iosxe-recomm-1.cisco.com", |
| 59 | + "username": "developer", |
| 60 | + "password": "C1sco12345", |
| 61 | + "netconf_port": 830, |
| 62 | + "restconf_port": 443, |
| 63 | + "ssh_port": 22 |
| 64 | + } |
| 65 | + |
| 66 | + # Values for the Reservable IOS XE Sandbox |
| 67 | + IOS_XE_2 = { |
| 68 | + "host": "10.10.20.48", |
| 69 | + "username": "developer", |
| 70 | + "password": "C1sco12345", |
| 71 | + "netconf_port": 830, |
| 72 | + "restconf_port": 443, |
| 73 | + "ssh_port": 22 |
| 74 | + } |
| 75 | + |
| 76 | + # Values for the Always On NX-OS Sandbox |
| 77 | + NXOS_1 = { |
| 78 | + "host": "sbx-nxos-mgmt.cisco.com", |
| 79 | + "username": "admin", |
| 80 | + "password": "Admin_1234!", |
| 81 | + "netconf_port": 10000, |
| 82 | + "restconf_port": 443, |
| 83 | + "nxapi_port": 80, |
| 84 | + "ssh_port": 8181 |
| 85 | + } |
| 86 | + |
| 87 | +elif ENVIRONMENT_IN_USE == "express": |
| 88 | + DNA_CENTER = { |
| 89 | + "host": "sandboxdnac2.cisco.com", |
| 90 | + "port": 443, |
| 91 | + "username": "dnacdev", |
| 92 | + "password": "D3v93T@wK!" |
| 93 | + } |
| 94 | + |
| 95 | + NFVIS_SERVER = { |
| 96 | + "host": "198.18.134.46", |
| 97 | + "port": 443, |
| 98 | + "username": "admin", |
| 99 | + "password": "C1sco12345_" |
| 100 | + } |
| 101 | + |
| 102 | + # Values for the CSR1 from the dCloud Pod |
| 103 | + IOS_XE_1 = { |
| 104 | + "host": "198.18.134.11", |
| 105 | + "username": "admin", |
| 106 | + "password": "C1sco12345", |
| 107 | + "netconf_port": 830, |
| 108 | + "restconf_port": 443, |
| 109 | + "ssh_port": 22 |
| 110 | + } |
| 111 | + |
| 112 | + # Values for the CSR2 from the dCloud Pod |
| 113 | + IOS_XE_2 = { |
| 114 | + "host": "198.18.134.12", |
| 115 | + "username": "admin", |
| 116 | + "password": "C1sco12345", |
| 117 | + "netconf_port": 830, |
| 118 | + "restconf_port": 443, |
| 119 | + "ssh_port": 22 |
| 120 | + } |
| 121 | + |
| 122 | + # Values for the Always On NX-OS Sandbox |
| 123 | + NXOS_1 = { |
| 124 | + "host": "sbx-nxos-mgmt.cisco.com", |
| 125 | + "username": "admin", |
| 126 | + "password": "Admin_1234!", |
| 127 | + "netconf_port": 10000, |
| 128 | + "restconf_port": 443, |
| 129 | + "nxapi_port": 80, |
| 130 | + "ssh_port": 8181 |
| 131 | + } |
0 commit comments