You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

935 lines
27 KiB

  1. <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  2. <topology xmlns="http://www.cisco.com/VIRL" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" schemaVersion="0.95" xsi:schemaLocation="http://www.cisco.com/VIRL https://raw.github.com/CiscoVIRL/schema/v0.95/virl.xsd">
  3. <node name="Router-A" type="SIMPLE" subtype="IOSv" location="236,245">
  4. <extensions>
  5. <entry key="AutoNetkit.mgmt_ip" type="string"></entry>
  6. <entry key="AutoNetkit.IGP" type="String">eigrp</entry>
  7. <entry key="Auto-generate config" type="Boolean">false</entry>
  8. <entry key="config" type="String">!
  9. ! Last configuration change at 22:03:48 UTC Sun Jan 15 2017
  10. !
  11. version 15.6
  12. service timestamps debug datetime msec
  13. service timestamps log datetime msec
  14. no service password-encryption
  15. !
  16. hostname Router-A
  17. !
  18. boot-start-marker
  19. boot-end-marker
  20. !
  21. !
  22. vrf definition Mgmt-intf
  23. !
  24. address-family ipv4
  25. exit-address-family
  26. !
  27. address-family ipv6
  28. exit-address-family
  29. !
  30. enable password cisco
  31. !
  32. no aaa new-model
  33. ethernet lmi ce
  34. !
  35. !
  36. !
  37. mmi polling-interval 60
  38. no mmi auto-configure
  39. no mmi pvc
  40. mmi snmp-timeout 180
  41. !
  42. !
  43. !
  44. !
  45. !
  46. !
  47. !
  48. !
  49. !
  50. !
  51. !
  52. no ip domain lookup
  53. ip cef
  54. ipv6 unicast-routing
  55. ipv6 cef
  56. !
  57. multilink bundle-name authenticated
  58. !
  59. !
  60. !
  61. !
  62. !
  63. redundancy
  64. !
  65. no cdp run
  66. !
  67. !
  68. !
  69. !
  70. !
  71. !
  72. !
  73. !
  74. !
  75. !
  76. !
  77. !
  78. !
  79. !
  80. interface Loopback0
  81. description Loopback
  82. ip address 192.168.0.2 255.255.255.255
  83. !
  84. interface GigabitEthernet0/0
  85. description OOB Management
  86. vrf forwarding Mgmt-intf
  87. ip address 10.255.0.229 255.255.0.0
  88. duplex full
  89. speed auto
  90. media-type rj45
  91. !
  92. interface GigabitEthernet0/1
  93. description to ISP
  94. ip address 192.168.101.2 255.255.255.252
  95. duplex full
  96. speed auto
  97. media-type rj45
  98. !
  99. interface GigabitEthernet0/2
  100. description toRechnungswesen
  101. ip address 192.168.100.1 255.255.255.128
  102. duplex auto
  103. speed auto
  104. media-type rj45
  105. !
  106. interface GigabitEthernet0/3
  107. description toManagement
  108. ip address 192.168.100.129 255.255.255.192
  109. duplex auto
  110. speed auto
  111. media-type rj45
  112. !
  113. interface GigabitEthernet0/4
  114. description toAdministration
  115. ip address 192.168.100.193 255.255.255.240
  116. duplex auto
  117. speed auto
  118. media-type rj45
  119. !
  120. ip forward-protocol nd
  121. !
  122. !
  123. no ip http server
  124. no ip http secure-server
  125. ip route 0.0.0.0 0.0.0.0 192.168.101.1
  126. !
  127. !
  128. !
  129. !
  130. control-plane
  131. !
  132. banner exec `
  133. **************************************************************************
  134. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  135. * education. IOSv is provided as-is and is not supported by Cisco's *
  136. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  137. * of the IOSv Software or Documentation to any third party for any *
  138. * purposes is expressly prohibited except as otherwise authorized by *
  139. * Cisco in writing. *
  140. **************************************************************************`
  141. banner incoming `
  142. **************************************************************************
  143. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  144. * education. IOSv is provided as-is and is not supported by Cisco's *
  145. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  146. * of the IOSv Software or Documentation to any third party for any *
  147. * purposes is expressly prohibited except as otherwise authorized by *
  148. * Cisco in writing. *
  149. **************************************************************************`
  150. banner login `
  151. **************************************************************************
  152. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  153. * education. IOSv is provided as-is and is not supported by Cisco's *
  154. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  155. * of the IOSv Software or Documentation to any third party for any *
  156. * purposes is expressly prohibited except as otherwise authorized by *
  157. * Cisco in writing. *
  158. **************************************************************************`
  159. !
  160. line con 0
  161. password cisco
  162. line aux 0
  163. line vty 0 4
  164. exec-timeout 720 0
  165. password cisco
  166. login
  167. transport input telnet ssh
  168. !
  169. no scheduler allocate
  170. !
  171. end</entry>
  172. </extensions>
  173. <interface id="0" name="GigabitEthernet0/1" ipv4="192.168.101.2" netPrefixLenV4="24"/>
  174. <interface id="1" name="GigabitEthernet0/2" ipv4="192.168.1.1" netPrefixLenV4="24"/>
  175. <interface id="2" name="GigabitEthernet0/3"/>
  176. <interface id="3" name="GigabitEthernet0/4"/>
  177. </node>
  178. <node name="Router-B" type="SIMPLE" subtype="IOSv" location="463,232">
  179. <extensions>
  180. <entry key="AutoNetkit.mgmt_ip" type="string"></entry>
  181. <entry key="Auto-generate config" type="Boolean">false</entry>
  182. <entry key="config" type="String">!
  183. ! Last configuration change at 22:03:51 UTC Sun Jan 15 2017
  184. !
  185. version 15.6
  186. service timestamps debug datetime msec
  187. service timestamps log datetime msec
  188. no service password-encryption
  189. !
  190. hostname Router-B
  191. !
  192. boot-start-marker
  193. boot-end-marker
  194. !
  195. !
  196. vrf definition Mgmt-intf
  197. !
  198. address-family ipv4
  199. exit-address-family
  200. !
  201. address-family ipv6
  202. exit-address-family
  203. !
  204. enable password cisco
  205. !
  206. no aaa new-model
  207. ethernet lmi ce
  208. !
  209. !
  210. !
  211. mmi polling-interval 60
  212. no mmi auto-configure
  213. no mmi pvc
  214. mmi snmp-timeout 180
  215. !
  216. !
  217. !
  218. !
  219. !
  220. !
  221. !
  222. !
  223. !
  224. !
  225. !
  226. no ip domain lookup
  227. ip cef
  228. ipv6 unicast-routing
  229. ipv6 cef
  230. !
  231. multilink bundle-name authenticated
  232. !
  233. !
  234. !
  235. !
  236. !
  237. redundancy
  238. !
  239. no cdp run
  240. !
  241. !
  242. !
  243. !
  244. !
  245. !
  246. !
  247. !
  248. !
  249. !
  250. !
  251. !
  252. !
  253. !
  254. interface Loopback0
  255. description Loopback
  256. ip address 192.168.0.3 255.255.255.255
  257. !
  258. interface GigabitEthernet0/0
  259. description OOB Management
  260. vrf forwarding Mgmt-intf
  261. ip address 10.255.0.230 255.255.0.0
  262. duplex full
  263. speed auto
  264. media-type rj45
  265. !
  266. interface GigabitEthernet0/1
  267. description to ISP
  268. ip address 192.168.102.2 255.255.255.252
  269. ip ospf cost 1
  270. duplex full
  271. speed auto
  272. media-type rj45
  273. !
  274. interface GigabitEthernet0/2
  275. description toServer
  276. ip address 192.168.32.1 255.255.254.0
  277. duplex auto
  278. speed auto
  279. media-type rj45
  280. !
  281. ip forward-protocol nd
  282. !
  283. !
  284. no ip http server
  285. no ip http secure-server
  286. ip route 0.0.0.0 0.0.0.0 192.168.102.1
  287. !
  288. !
  289. !
  290. !
  291. control-plane
  292. !
  293. banner exec `
  294. **************************************************************************
  295. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  296. * education. IOSv is provided as-is and is not supported by Cisco's *
  297. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  298. * of the IOSv Software or Documentation to any third party for any *
  299. * purposes is expressly prohibited except as otherwise authorized by *
  300. * Cisco in writing. *
  301. **************************************************************************`
  302. banner incoming `
  303. **************************************************************************
  304. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  305. * education. IOSv is provided as-is and is not supported by Cisco's *
  306. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  307. * of the IOSv Software or Documentation to any third party for any *
  308. * purposes is expressly prohibited except as otherwise authorized by *
  309. * Cisco in writing. *
  310. **************************************************************************`
  311. banner login `
  312. **************************************************************************
  313. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  314. * education. IOSv is provided as-is and is not supported by Cisco's *
  315. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  316. * of the IOSv Software or Documentation to any third party for any *
  317. * purposes is expressly prohibited except as otherwise authorized by *
  318. * Cisco in writing. *
  319. **************************************************************************`
  320. !
  321. line con 0
  322. password cisco
  323. line aux 0
  324. line vty 0 4
  325. exec-timeout 720 0
  326. password cisco
  327. login
  328. transport input telnet ssh
  329. !
  330. no scheduler allocate
  331. !
  332. end</entry>
  333. </extensions>
  334. <interface id="0" name="GigabitEthernet0/1"/>
  335. <interface id="1" name="GigabitEthernet0/2" netPrefixLenV4="24"/>
  336. </node>
  337. <node name="Internet&#xD;&#xA;" type="ASSET" subtype="FLAT" location="391,42">
  338. <extensions>
  339. <entry key="host_network" type="String">flat</entry>
  340. </extensions>
  341. <interface id="0" name="link0"/>
  342. </node>
  343. <node name="Switch-A" type="SIMPLE" subtype="IOSvL2" location="552,358">
  344. <extensions>
  345. <entry key="AutoNetkit.mgmt_ip" type="string"></entry>
  346. <entry key="Auto-generate config" type="Boolean">false</entry>
  347. <entry key="config" type="String">!
  348. ! Last configuration change at 22:03:41 UTC Sun Jan 15 2017
  349. !
  350. version 15.2
  351. service timestamps debug datetime msec
  352. service timestamps log datetime msec
  353. no service password-encryption
  354. service compress-config
  355. !
  356. hostname Switch-A
  357. !
  358. boot-start-marker
  359. boot-end-marker
  360. !
  361. !
  362. vrf definition Mgmt-intf
  363. !
  364. address-family ipv4
  365. exit-address-family
  366. !
  367. address-family ipv6
  368. exit-address-family
  369. !
  370. enable password cisco
  371. !
  372. no aaa new-model
  373. !
  374. !
  375. !
  376. !
  377. !
  378. !
  379. !
  380. !
  381. no ip domain-lookup
  382. ip cef
  383. no ipv6 cef
  384. !
  385. !
  386. !
  387. spanning-tree mode pvst
  388. spanning-tree extend system-id
  389. !
  390. vlan internal allocation policy ascending
  391. !
  392. !
  393. !
  394. !
  395. !
  396. !
  397. !
  398. !
  399. !
  400. !
  401. !
  402. !
  403. !
  404. !
  405. interface Loopback0
  406. description Loopback
  407. no ip address
  408. !
  409. interface GigabitEthernet0/1
  410. description to Router-B
  411. switchport access vlan 2
  412. switchport mode access
  413. media-type rj45
  414. negotiation auto
  415. !
  416. interface GigabitEthernet0/2
  417. description to Server-A
  418. switchport access vlan 2
  419. switchport mode access
  420. media-type rj45
  421. negotiation auto
  422. !
  423. interface GigabitEthernet0/3
  424. description to Server-B
  425. switchport access vlan 2
  426. switchport mode access
  427. media-type rj45
  428. negotiation auto
  429. !
  430. interface GigabitEthernet0/0
  431. description OOB management
  432. no switchport
  433. ip address 10.255.0.231 255.255.0.0
  434. negotiation auto
  435. !
  436. ip forward-protocol nd
  437. !
  438. no ip http server
  439. no ip http secure-server
  440. !
  441. !
  442. !
  443. !
  444. !
  445. !
  446. control-plane
  447. !
  448. banner exec `
  449. **************************************************************************
  450. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  451. * education. IOSv is provided as-is and is not supported by Cisco's *
  452. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  453. * of the IOSv Software or Documentation to any third party for any *
  454. * purposes is expressly prohibited except as otherwise authorized by *
  455. * Cisco in writing. *
  456. **************************************************************************`
  457. banner incoming `
  458. **************************************************************************
  459. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  460. * education. IOSv is provided as-is and is not supported by Cisco's *
  461. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  462. * of the IOSv Software or Documentation to any third party for any *
  463. * purposes is expressly prohibited except as otherwise authorized by *
  464. * Cisco in writing. *
  465. **************************************************************************`
  466. banner login `
  467. **************************************************************************
  468. * IOSv is strictly limited to use for evaluation, demonstration and IOS *
  469. * education. IOSv is provided as-is and is not supported by Cisco's *
  470. * Technical Advisory Center. Any use or disclosure, in whole or in part, *
  471. * of the IOSv Software or Documentation to any third party for any *
  472. * purposes is expressly prohibited except as otherwise authorized by *
  473. * Cisco in writing. *
  474. **************************************************************************`
  475. !
  476. line con 0
  477. password cisco
  478. line aux 0
  479. line vty 0 4
  480. exec-timeout 720 0
  481. password cisco
  482. login
  483. transport input telnet ssh
  484. !
  485. mac address-table aging-time 10
  486. !
  487. end</entry>
  488. </extensions>
  489. <interface id="0" name="GigabitEthernet0/1"/>
  490. <interface id="1" name="GigabitEthernet0/2"/>
  491. <interface id="2" name="GigabitEthernet0/3"/>
  492. </node>
  493. <node name="ISP" type="SIMPLE" subtype="lxc" location="343,149">
  494. <extensions>
  495. <entry key="Auto-generate config" type="Boolean">false</entry>
  496. <entry key="config" type="String">#cloud-config&#xD;
  497. bootcmd:&#xD;
  498. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  499. hostname: ISP&#xD;
  500. manage_etc_hosts: true&#xD;
  501. runcmd:&#xD;
  502. - start ttyS0&#xD;
  503. - systemctl start getty@ttyS0.service&#xD;
  504. - systemctl start rc-local&#xD;
  505. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  506. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  507. - service ssh restart&#xD;
  508. - service sshd restart&#xD;
  509. users:&#xD;
  510. - default&#xD;
  511. - gecos: User configured by VIRL Configuration Engine 0.23.9&#xD;
  512. lock-passwd: false&#xD;
  513. name: cisco&#xD;
  514. plain-text-passwd: cisco&#xD;
  515. shell: /bin/bash&#xD;
  516. ssh-authorized-keys:&#xD;
  517. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  518. sudo: ALL=(ALL) ALL&#xD;
  519. write_files:&#xD;
  520. - path: /etc/init/ttyS0.conf&#xD;
  521. owner: root:root&#xD;
  522. content: |&#xD;
  523. # ttyS0 - getty&#xD;
  524. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  525. # started until it is shut down again.&#xD;
  526. start on stopped rc or RUNLEVEL=[12345]&#xD;
  527. stop on runlevel [!12345]&#xD;
  528. respawn&#xD;
  529. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  530. permissions: '0644'&#xD;
  531. - path: /etc/systemd/system/dhclient@.service&#xD;
  532. content: |&#xD;
  533. [Unit]&#xD;
  534. Description=Run dhclient on %i interface&#xD;
  535. After=network.target&#xD;
  536. [Service]&#xD;
  537. Type=oneshot&#xD;
  538. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  539. RemainAfterExit=yes&#xD;
  540. owner: root:root&#xD;
  541. permissions: '0644'&#xD;
  542. - path: /etc/rc.local&#xD;
  543. owner: root:root&#xD;
  544. permissions: '0755'&#xD;
  545. content: |-&#xD;
  546. #!/bin/sh&#xD;
  547. ifconfig eth1 up 192.168.101.1 netmask 255.255.255.252&#xD;
  548. ifconfig eth2 up 192.168.102.1 netmask 255.255.255.252&#xD;
  549. &#xD;
  550. dhclient eth0&#xD;
  551. dhclient eth3&#xD;
  552. &#xD;
  553. echo 1 &gt; /proc/sys/net/ipv4/ip_forward&#xD;
  554. &#xD;
  555. route add default gw 172.16.1.1 eth3&#xD;
  556. &#xD;
  557. route add -net 192.168.101.0/30 gw 192.168.101.2 dev eth1&#xD;
  558. route add -net 192.168.102.0/30 gw 192.168.102.2 dev eth2&#xD;
  559. &#xD;
  560. route add -net 192.168.100.0/24 gw 192.168.101.2 dev eth1&#xD;
  561. route add -net 192.168.32.0/20 gw 192.168.102.2 dev eth2&#xD;
  562. &#xD;
  563. iptables -t nat -A POSTROUTING -o eth3 -j MASQUERADE&#xD;
  564. iptables -P FORWARD ACCEPT&#xD;
  565. iptables -F FORWARD&#xD;
  566. &#xD;
  567. iptables -t nat -A PREROUTING -i eth3 -p tcp -m tcp --dport 80 -j DNAT --to-destination 192.168.2.100:80&#xD;
  568. iptables -t nat -A PREROUTING -i eth3 -p tcp -m tcp --dport 22 -j DNAT --to-destination 192.168.2.100:22&#xD;
  569. &#xD;
  570. /sbin/tc qdisc add dev eth2 root handle 1:1 netem delay 100ms loss 5%&#xD;
  571. echo "alias unbug='sudo tc qdisc del dev eth2 root'" &gt;&gt;/home/cisco/.bashrc&#xD;
  572. &#xD;
  573. service ssh start&#xD;
  574. &#xD;
  575. hostname ISP&#xD;
  576. &#xD;
  577. exit 0&#xD;
  578. &#xD;
  579. </entry>
  580. </extensions>
  581. <interface id="0" name="eth1"/>
  582. <interface id="1" name="eth2"/>
  583. <interface id="2" name="eth3"/>
  584. </node>
  585. <node name="Server-B" type="SIMPLE" subtype="lxc" location="393,364">
  586. <extensions>
  587. <entry key="Auto-generate config" type="Boolean">false</entry>
  588. <entry key="config" type="String">#cloud-config&#xD;
  589. bootcmd:&#xD;
  590. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  591. hostname: Server-B&#xD;
  592. manage_etc_hosts: true&#xD;
  593. &#xD;
  594. runcmd:&#xD;
  595. - start ttyS0&#xD;
  596. - systemctl start getty@ttyS0.service&#xD;
  597. - systemctl start rc-local&#xD;
  598. - systemctl start install-webserver&#xD;
  599. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  600. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  601. - service ssh restart&#xD;
  602. - service sshd restart&#xD;
  603. users:&#xD;
  604. - default&#xD;
  605. - gecos: User configured by VIRL Configuration Engine 0.18.9&#xD;
  606. lock-passwd: false&#xD;
  607. name: cisco&#xD;
  608. plain-text-passwd: cisco&#xD;
  609. shell: /bin/bash&#xD;
  610. ssh-authorized-keys:&#xD;
  611. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  612. sudo: ALL=(ALL) ALL&#xD;
  613. write_files:&#xD;
  614. - path: /etc/init/ttyS0.conf&#xD;
  615. owner: root:root&#xD;
  616. content: |&#xD;
  617. # ttyS0 - getty&#xD;
  618. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  619. # started until it is shut down again.&#xD;
  620. start on stopped rc or RUNLEVEL=[12345]&#xD;
  621. stop on runlevel [!12345]&#xD;
  622. respawn&#xD;
  623. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  624. permissions: '0644'&#xD;
  625. - path: /etc/systemd/system/dhclient@.service&#xD;
  626. content: |&#xD;
  627. [Unit]&#xD;
  628. Description=Run dhclient on %i interface&#xD;
  629. After=network.target&#xD;
  630. [Service]&#xD;
  631. Type=oneshot&#xD;
  632. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  633. RemainAfterExit=yes&#xD;
  634. owner: root:root&#xD;
  635. permissions: '0644'&#xD;
  636. - path: /etc/rc.local&#xD;
  637. owner: root:root&#xD;
  638. permissions: '0755'&#xD;
  639. content: |-&#xD;
  640. #!/bin/sh -e&#xD;
  641. echo "nameserver 8.8.8.8" &gt;/etc/resolv.conf&#xD;
  642. ifconfig eth1 192.168.32.10 netmask 255.255.254.0&#xD;
  643. route del default&#xD;
  644. route add default gw 192.168.32.1&#xD;
  645. exit 0&#xD;
  646. &#xD;
  647. </entry>
  648. </extensions>
  649. <interface id="0" name="eth1"/>
  650. </node>
  651. <node name="Server-A" type="SIMPLE" subtype="lxc" location="639,256">
  652. <extensions>
  653. <entry key="Auto-generate config" type="Boolean">false</entry>
  654. <entry key="config" type="String">#cloud-config&#xD;
  655. bootcmd:&#xD;
  656. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  657. hostname: Server-A&#xD;
  658. manage_etc_hosts: true&#xD;
  659. runcmd:&#xD;
  660. - start ttyS0&#xD;
  661. - systemctl start getty@ttyS0.service&#xD;
  662. - systemctl start rc-local&#xD;
  663. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  664. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  665. - service ssh restart&#xD;
  666. - service sshd restart&#xD;
  667. users:&#xD;
  668. - default&#xD;
  669. - gecos: User configured by VIRL Configuration Engine 0.18.9&#xD;
  670. lock-passwd: false&#xD;
  671. name: cisco&#xD;
  672. plain-text-passwd: cisco&#xD;
  673. shell: /bin/bash&#xD;
  674. ssh-authorized-keys:&#xD;
  675. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  676. sudo: ALL=(ALL) ALL&#xD;
  677. write_files:&#xD;
  678. - path: /etc/init/ttyS0.conf&#xD;
  679. owner: root:root&#xD;
  680. content: |&#xD;
  681. # ttyS0 - getty&#xD;
  682. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  683. # started until it is shut down again.&#xD;
  684. start on stopped rc or RUNLEVEL=[12345]&#xD;
  685. stop on runlevel [!12345]&#xD;
  686. respawn&#xD;
  687. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  688. permissions: '0644'&#xD;
  689. - path: /etc/systemd/system/dhclient@.service&#xD;
  690. content: |&#xD;
  691. [Unit]&#xD;
  692. Description=Run dhclient on %i interface&#xD;
  693. After=network.target&#xD;
  694. [Service]&#xD;
  695. Type=oneshot&#xD;
  696. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  697. RemainAfterExit=yes&#xD;
  698. owner: root:root&#xD;
  699. permissions: '0644'&#xD;
  700. - path: /etc/rc.local&#xD;
  701. owner: root:root&#xD;
  702. permissions: '0755'&#xD;
  703. content: |-&#xD;
  704. #!/bin/sh -e&#xD;
  705. ifconfig eth1 192.168.32.20&#xD;
  706. route del default&#xD;
  707. route add default gw 192.168.32.1&#xD;
  708. exit 0&#xD;
  709. &#xD;
  710. - path: /etc/resolv.conf&#xD;
  711. owner: root:root&#xD;
  712. permissions: '0644'&#xD;
  713. content: |&#xD;
  714. nameserver 8.8.8.8</entry>
  715. </extensions>
  716. <interface id="0" name="eth1"/>
  717. </node>
  718. <node name="Management-Client" type="SIMPLE" subtype="lxc" location="146,372">
  719. <extensions>
  720. <entry key="Auto-generate config" type="Boolean">false</entry>
  721. <entry key="config" type="String">#cloud-config&#xD;
  722. bootcmd:&#xD;
  723. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  724. hostname: Client&#xD;
  725. manage_etc_hosts: true&#xD;
  726. runcmd:&#xD;
  727. - start ttyS0&#xD;
  728. - systemctl start getty@ttyS0.service&#xD;
  729. - systemctl start rc-local&#xD;
  730. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  731. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  732. - service ssh restart&#xD;
  733. - service sshd restart&#xD;
  734. users:&#xD;
  735. - default&#xD;
  736. - gecos: User configured by VIRL Configuration Engine 0.18.9&#xD;
  737. lock-passwd: false&#xD;
  738. name: cisco&#xD;
  739. plain-text-passwd: cisco&#xD;
  740. shell: /bin/bash&#xD;
  741. ssh-authorized-keys:&#xD;
  742. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  743. sudo: ALL=(ALL) ALL&#xD;
  744. write_files:&#xD;
  745. - path: /etc/init/ttyS0.conf&#xD;
  746. owner: root:root&#xD;
  747. content: |&#xD;
  748. # ttyS0 - getty&#xD;
  749. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  750. # started until it is shut down again.&#xD;
  751. start on stopped rc or RUNLEVEL=[12345]&#xD;
  752. stop on runlevel [!12345]&#xD;
  753. respawn&#xD;
  754. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  755. permissions: '0644'&#xD;
  756. - path: /etc/systemd/system/dhclient@.service&#xD;
  757. content: |&#xD;
  758. [Unit]&#xD;
  759. Description=Run dhclient on %i interface&#xD;
  760. After=network.target&#xD;
  761. [Service]&#xD;
  762. Type=oneshot&#xD;
  763. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  764. RemainAfterExit=yes&#xD;
  765. owner: root:root&#xD;
  766. permissions: '0644'&#xD;
  767. - path: /etc/rc.local&#xD;
  768. owner: root:root&#xD;
  769. permissions: '0755'&#xD;
  770. content: |-&#xD;
  771. !/bin/sh -e&#xD;
  772. ifconfig eth1 192.168.100.130 netmask 255.255.255.192&#xD;
  773. route del default&#xD;
  774. route add default gw 192.168.100.129&#xD;
  775. exit 0&#xD;
  776. &#xD;
  777. - path: /etc/resolv.conf&#xD;
  778. owner: root:root&#xD;
  779. permissions: '0644'&#xD;
  780. content: |&#xD;
  781. #by Patrick.&#xD;
  782. nameserver 8.8.8.8&#xD;
  783. </entry>
  784. </extensions>
  785. <interface id="0" name="eth1"/>
  786. </node>
  787. <node name="Administration-Client" type="SIMPLE" subtype="lxc" location="234,437">
  788. <extensions>
  789. <entry key="Auto-generate config" type="Boolean">false</entry>
  790. <entry key="config" type="String">#cloud-config&#xD;
  791. bootcmd:&#xD;
  792. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  793. hostname: Client&#xD;
  794. manage_etc_hosts: true&#xD;
  795. runcmd:&#xD;
  796. - start ttyS0&#xD;
  797. - systemctl start getty@ttyS0.service&#xD;
  798. - systemctl start rc-local&#xD;
  799. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  800. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  801. - service ssh restart&#xD;
  802. - service sshd restart&#xD;
  803. users:&#xD;
  804. - default&#xD;
  805. - gecos: User configured by VIRL Configuration Engine 0.18.9&#xD;
  806. lock-passwd: false&#xD;
  807. name: cisco&#xD;
  808. plain-text-passwd: cisco&#xD;
  809. shell: /bin/bash&#xD;
  810. ssh-authorized-keys:&#xD;
  811. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  812. sudo: ALL=(ALL) ALL&#xD;
  813. write_files:&#xD;
  814. - path: /etc/init/ttyS0.conf&#xD;
  815. owner: root:root&#xD;
  816. content: |&#xD;
  817. # ttyS0 - getty&#xD;
  818. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  819. # started until it is shut down again.&#xD;
  820. start on stopped rc or RUNLEVEL=[12345]&#xD;
  821. stop on runlevel [!12345]&#xD;
  822. respawn&#xD;
  823. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  824. permissions: '0644'&#xD;
  825. - path: /etc/systemd/system/dhclient@.service&#xD;
  826. content: |&#xD;
  827. [Unit]&#xD;
  828. Description=Run dhclient on %i interface&#xD;
  829. After=network.target&#xD;
  830. [Service]&#xD;
  831. Type=oneshot&#xD;
  832. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  833. RemainAfterExit=yes&#xD;
  834. owner: root:root&#xD;
  835. permissions: '0644'&#xD;
  836. - path: /etc/rc.local&#xD;
  837. owner: root:root&#xD;
  838. permissions: '0755'&#xD;
  839. content: |-&#xD;
  840. !/bin/sh -e&#xD;
  841. ifconfig eth1 192.168.100.194 netmask 255.255.255.240&#xD;
  842. route del default&#xD;
  843. route add default gw 192.168.100.193&#xD;
  844. exit 0&#xD;
  845. &#xD;
  846. - path: /etc/resolv.conf&#xD;
  847. owner: root:root&#xD;
  848. permissions: '0644'&#xD;
  849. content: |&#xD;
  850. #by Patrick.&#xD;
  851. nameserver 8.8.8.8&#xD;
  852. </entry>
  853. </extensions>
  854. <interface id="0" name="eth1"/>
  855. </node>
  856. <node name="Rechnungswesen-Client" type="SIMPLE" subtype="lxc" location="61,296">
  857. <extensions>
  858. <entry key="Auto-generate config" type="Boolean">false</entry>
  859. <entry key="config" type="String">#cloud-config&#xD;
  860. bootcmd:&#xD;
  861. - ln -s -t /etc/rc.d /etc/rc.local&#xD;
  862. hostname: Client&#xD;
  863. manage_etc_hosts: true&#xD;
  864. runcmd:&#xD;
  865. - start ttyS0&#xD;
  866. - systemctl start getty@ttyS0.service&#xD;
  867. - systemctl start rc-local&#xD;
  868. - sed -i '/^\s*PasswordAuthentication\s\+no/d' /etc/ssh/sshd_config&#xD;
  869. - echo "UseDNS no" &gt;&gt; /etc/ssh/sshd_config&#xD;
  870. - service ssh restart&#xD;
  871. - service sshd restart&#xD;
  872. users:&#xD;
  873. - default&#xD;
  874. - gecos: User configured by VIRL Configuration Engine 0.18.9&#xD;
  875. lock-passwd: false&#xD;
  876. name: cisco&#xD;
  877. plain-text-passwd: cisco&#xD;
  878. shell: /bin/bash&#xD;
  879. ssh-authorized-keys:&#xD;
  880. - VIRL-USER-SSH-PUBLIC-KEY&#xD;
  881. sudo: ALL=(ALL) ALL&#xD;
  882. write_files:&#xD;
  883. - path: /etc/init/ttyS0.conf&#xD;
  884. owner: root:root&#xD;
  885. content: |&#xD;
  886. # ttyS0 - getty&#xD;
  887. # This service maintains a getty on ttyS0 from the point the system is&#xD;
  888. # started until it is shut down again.&#xD;
  889. start on stopped rc or RUNLEVEL=[12345]&#xD;
  890. stop on runlevel [!12345]&#xD;
  891. respawn&#xD;
  892. exec /sbin/getty -L 115200 ttyS0 vt102&#xD;
  893. permissions: '0644'&#xD;
  894. - path: /etc/systemd/system/dhclient@.service&#xD;
  895. content: |&#xD;
  896. [Unit]&#xD;
  897. Description=Run dhclient on %i interface&#xD;
  898. After=network.target&#xD;
  899. [Service]&#xD;
  900. Type=oneshot&#xD;
  901. ExecStart=/sbin/dhclient %i -pf /var/run/dhclient.%i.pid -lf /var/lib/dhclient/dhclient.%i.lease&#xD;
  902. RemainAfterExit=yes&#xD;
  903. owner: root:root&#xD;
  904. permissions: '0644'&#xD;
  905. - path: /etc/rc.local&#xD;
  906. owner: root:root&#xD;
  907. permissions: '0755'&#xD;
  908. content: |-&#xD;
  909. !/bin/sh -e&#xD;
  910. ifconfig eth1 192.168.100.10 netmask 255.255.255.128&#xD;
  911. route del default&#xD;
  912. route add default gw 192.168.100.1&#xD;
  913. exit 0&#xD;
  914. &#xD;
  915. - path: /etc/resolv.conf&#xD;
  916. owner: root:root&#xD;
  917. permissions: '0644'&#xD;
  918. content: |&#xD;
  919. #by Patrick.&#xD;
  920. nameserver 8.8.8.8&#xD;
  921. </entry>
  922. </extensions>
  923. <interface id="0" name="eth1"/>
  924. </node>
  925. <annotations/>
  926. <connection dst="/virl:topology/virl:node[4]/virl:interface[1]" src="/virl:topology/virl:node[2]/virl:interface[2]"/>
  927. <connection dst="/virl:topology/virl:node[5]/virl:interface[1]" src="/virl:topology/virl:node[1]/virl:interface[1]"/>
  928. <connection dst="/virl:topology/virl:node[2]/virl:interface[1]" src="/virl:topology/virl:node[5]/virl:interface[2]"/>
  929. <connection dst="/virl:topology/virl:node[5]/virl:interface[3]" src="/virl:topology/virl:node[3]/virl:interface[1]"/>
  930. <connection dst="/virl:topology/virl:node[4]/virl:interface[3]" src="/virl:topology/virl:node[6]/virl:interface[1]"/>
  931. <connection dst="/virl:topology/virl:node[4]/virl:interface[2]" src="/virl:topology/virl:node[7]/virl:interface[1]"/>
  932. <connection dst="/virl:topology/virl:node[1]/virl:interface[2]" src="/virl:topology/virl:node[10]/virl:interface[1]"/>
  933. <connection dst="/virl:topology/virl:node[1]/virl:interface[3]" src="/virl:topology/virl:node[8]/virl:interface[1]"/>
  934. <connection dst="/virl:topology/virl:node[1]/virl:interface[4]" src="/virl:topology/virl:node[9]/virl:interface[1]"/>
  935. </topology>