mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-14 10:55:15 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a295d653b8 | ||
|
|
c6eec799fb | ||
|
|
8503840307 | ||
|
|
c4dbecc1ea | ||
|
|
3d71967983 | ||
|
|
161e016594 | ||
|
|
82f795c9ee | ||
|
|
2670c68467 | ||
|
|
6f7730c455 | ||
|
|
274cef6cf5 | ||
|
|
fbea9b655d | ||
|
|
6869f2d71d | ||
|
|
e871a1aed6 | ||
|
|
b222fba42c | ||
|
|
f9957b1d90 | ||
|
|
bc6374f7fc | ||
|
|
c739a16d70 | ||
|
|
7684ce60ce | ||
|
|
e5ff9e7f00 | ||
|
|
7adb0c5226 | ||
|
|
667833dda5 | ||
|
|
646ff00ade | ||
|
|
ffcfa4ccb1 | ||
|
|
5c63928636 | ||
|
|
0624c1b945 | ||
|
|
b658f7ff68 | ||
|
|
cd51afb01f | ||
|
|
14ffa2c2d6 | ||
|
|
09aaf43dd1 | ||
|
|
590eedeb46 | ||
|
|
d3710e8e9a | ||
|
|
0da1a6639a | ||
|
|
729eb43115 | ||
|
|
4d85e517b4 | ||
|
|
3b95859b79 | ||
|
|
47cc827c1f | ||
|
|
715b7032bc | ||
|
|
bc1729b255 | ||
|
|
3dd4184193 | ||
|
|
2b4a05eedd | ||
|
|
898a9ce208 | ||
|
|
dd87ccff4d | ||
|
|
78c7d36b1c | ||
|
|
44d4a426b5 | ||
|
|
3273f7e992 | ||
|
|
d2d19b43c2 | ||
|
|
fe2014854e | ||
|
|
ebe4fdc5b5 |
No files matched your search
@@ -1,5 +1,21 @@
|
||||
# Change Log
|
||||
|
||||
## 2.2.58 10/04/2026
|
||||
|
||||
* Bundle web-ui v2.2.58
|
||||
* Sync appliances
|
||||
* Snapshot refactoring
|
||||
|
||||
## 2.2.57 23/03/2026
|
||||
|
||||
* feat(telnet_server): improve error handling and connection management
|
||||
* Deactivate 'use default IOU values' by default and update RAM/NVRAM values
|
||||
* Make sure the node shows as stopped when the wrap console cannot be stopped
|
||||
* tests(controller,port): short_name finishes successfully when port name is None
|
||||
* fix(controller,port): handle None port name to prevent TypeError in short_name method
|
||||
* fix: busybox static link detection on Alpine/musl
|
||||
* Take populated disks into consideration when calculating PCI device ID
|
||||
|
||||
## 2.2.56.1 28/01/2026
|
||||
|
||||
* Fix telnet keepalive options on macOS
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@ RUN apt-get update && apt-get install -y \
|
||||
RUN locale-gen en_US.UTF-8
|
||||
|
||||
# Install uninstall to install dependencies
|
||||
RUN apt-get install -y vpcs ubridge
|
||||
RUN apt-get install -y vpcs ubridge dynamips
|
||||
|
||||
ADD . /server
|
||||
WORKDIR /server
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"appliance_id": "a2209414-88a6-403b-a2e1-477a057ec954",
|
||||
"name": "AlpiNet",
|
||||
"category": "guest",
|
||||
"description": "AlpiNet is a lightweight Alpine-based networking toolbox for GNS3.\n\nCOMPREHENSIVE TOOLKIT:\n• Network: ip, ifconfig, ping, traceroute, mtr, arping, nmap, tcpdump\n• Performance: iperf, iperf3\n• HTTP/Web: curl, wget\n• TCP/UDP: netcat, socat, telnet\n• Advanced: ethtool, bridge-utils, vlan\n• Firewall: iptables, ip6tables, nftables\n• File Transfer: FTP (lftp), TFTP, SSH (scp/sftp), rsync\n• DNS: host, nslookup, dig\n• System: nano, tmux, screen, htop, bash\n• Text Tools: grep, sed, awk, jq, less\n• Compression: tar, gzip\n• Utilities: tree, file, openssl\n\nType 'alpinet-tools' in the container for the complete tool list.\n\nOptimized for network testing, troubleshooting, and education.",
|
||||
"vendor_name": "AlpiNet Project",
|
||||
"vendor_url": "https://www.alpinelinux.org/",
|
||||
"product_name": "AlpiNet",
|
||||
"registry_version": 4,
|
||||
"status": "stable",
|
||||
"maintainer": "nazDridoy",
|
||||
"maintainer_email": "nazdridoy399@gmail.com",
|
||||
"usage": "The /root directory is persistent across restarts. Type 'alpinet-tools' to see all available utilities.",
|
||||
"symbol": "AlpiNet.svg",
|
||||
"docker": {
|
||||
"adapters": 1,
|
||||
"image": "gns3/alpinet:latest",
|
||||
"console_type": "telnet",
|
||||
"environment": "TERM=xterm"
|
||||
}
|
||||
}
|
||||
@@ -28,6 +28,13 @@
|
||||
"options": "-cpu host"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "vEOS64-lab-4.35.3F.qcow2",
|
||||
"version": "4.35.3F",
|
||||
"md5sum": "00d11e33dc4288f509441a4ab6319ca0",
|
||||
"filesize": 638910464,
|
||||
"download_url": "https://www.arista.com/en/support/software-download"
|
||||
},
|
||||
{
|
||||
"filename": "vEOS64-lab-4.33.2F.qcow2",
|
||||
"version": "4.33.2F",
|
||||
@@ -58,6 +65,13 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "4.35.3F",
|
||||
"images": {
|
||||
"hda_disk_image": "Aboot-veos-serial-8.0.2.iso",
|
||||
"hdb_disk_image": "vEOS64-lab-4.35.3F.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "4.33.2F",
|
||||
"images": {
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
{
|
||||
"appliance_id": "4aa78f74-c769-43e0-9ef1-5dd2cf1909c6",
|
||||
"name": "Asterfusion AsterNOS-VPP",
|
||||
"category": "router",
|
||||
"description": "AsterNOS-VPP leverages SONiC’s robust routing features and management capability with VPP’s high-performance data forwarding. It supports L3 routing, NAT, PPPoE, and VPN services. Minimum requirements: 4 vCPUs and 4GB RAM.",
|
||||
"description": "AsterNOS-VPP leverages SONiC’s robust routing features and management capability with VPP’s high-performance data forwarding. It supports L3 routing, NAT, PPPoE, and VPN services. Minimum requirements: 4 vCPUs and 8GB RAM.",
|
||||
"vendor_name": "Asterfusion",
|
||||
"vendor_url": "https://cloudswit.ch/product/sonic-enterprise-distribution/#vAsterNOS",
|
||||
"documentation_url": "https://docs.asternos.com/routing",
|
||||
@@ -10,23 +11,32 @@
|
||||
"status": "stable",
|
||||
"maintainer": "Asterfusion Product Team",
|
||||
"maintainer_email": "bd@cloudswit.ch",
|
||||
"availability": "with-registration",
|
||||
"images": [
|
||||
{
|
||||
"filename": "AsterNOS-VPP_V6.1-R0101P02_x86.img.gz",
|
||||
"version": "V6.1",
|
||||
"filename": "AsterNOS-VPP_V6.1-R0101P02_x86.img",
|
||||
"version": "6.1",
|
||||
"md5sum": "55834c3e8849ab226144d79ef76acf81",
|
||||
"filesize": 1318201015,
|
||||
"download_url": "https://asternos.dev/api/file/b2c9fd83-a9d3-46f3-9676-6b49dd481d6c",
|
||||
"comments": "Registration is required to download the image."
|
||||
"compression": "gzip"
|
||||
}
|
||||
],
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 4,
|
||||
"ram": 4096,
|
||||
"ram": 8192,
|
||||
"cpus": 4,
|
||||
"arch": "x86_64",
|
||||
"console_type": "telnet",
|
||||
"kvm": "require"
|
||||
}
|
||||
},
|
||||
"versions": [
|
||||
{
|
||||
"name": "6.1",
|
||||
"images": {
|
||||
"hda_disk_image": "AsterNOS-VPP_V6.1-R0101P02_x86.img"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
{
|
||||
"appliance_id": "924a2ef5-7b91-45ae-a1e4-7220338b76b0",
|
||||
"name": "Cisco Alpine Linux TRex",
|
||||
"category": "guest",
|
||||
"description": "Alpine Linux VM image configured to run Cisco's Trex traffic generator in stateless mode",
|
||||
"vendor_name": "Cisco",
|
||||
"vendor_url": "http://www.cisco.com/",
|
||||
"documentation_url": "https://trex-tgn.cisco.com/",
|
||||
"product_name": "Alpine Linux Virt",
|
||||
"product_url": "https://developer.cisco.com/modeling-labs/",
|
||||
"registry_version": 4,
|
||||
"status": "beta",
|
||||
"maintainer": "GNS3 Team",
|
||||
"maintainer_email": "developers@gns3.net",
|
||||
"usage": "By default, a \"cisco\" account with password \"cisco\" is created.",
|
||||
"port_name_format": "eth{0}",
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 3,
|
||||
"ram": 512,
|
||||
"hda_disk_interface": "virtio",
|
||||
"arch": "x86_64",
|
||||
"console_type": "vnc",
|
||||
"kvm": "allow"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "alpine-trex-3-21-3.qcow2",
|
||||
"version": "2.87",
|
||||
"md5sum": "54cf267bbc2ab7a1c71dc53bced6e128",
|
||||
"filesize": 465174528,
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "2.87",
|
||||
"images": {
|
||||
"hda_disk_image": "alpine-trex-3-21-3.qcow2"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -31,21 +31,21 @@
|
||||
"version": "9.22.1.1 CML",
|
||||
"md5sum": "250a924cdc2370208eaac9d1dc8dc9e3",
|
||||
"filesize": 379518976,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/cisco-modeling-labs-personal/cisco-modeling-labs-personal/CML-PERSONAL.html"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "asav9-18-2.qcow2",
|
||||
"version": "9.18.2 CML",
|
||||
"md5sum": "6f10fe106edfad9163625770a47a6b73",
|
||||
"filesize": 340262912,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/cisco-modeling-labs-personal/cisco-modeling-labs-personal/CML-PERSONAL.html"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "asav9-16-2.qcow2",
|
||||
"version": "9.16.2 CML",
|
||||
"md5sum": "1f8db97063a7f738fddc81ac880a906c",
|
||||
"filesize": 262078976,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/cisco-modeling-labs-personal/cisco-modeling-labs-personal/CML-PERSONAL.html"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "asav9-16-2.qcow2",
|
||||
|
||||
@@ -31,14 +31,14 @@
|
||||
"version": "17.12(1)",
|
||||
"md5sum": "e587e92186f42bdf69d7fa27f34425f7",
|
||||
"filesize": 2739404800,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "cat9kv-prd-17.10.01prd7.qcow2",
|
||||
"version": "17.10(1)",
|
||||
"md5sum": "ffdbace33d31deae33e2a920a96b79ef",
|
||||
"filesize": 2155806720,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -134,21 +134,21 @@
|
||||
"version": "16.5.1b",
|
||||
"md5sum": "ac11d33041b8ff6dc3553e324d02cccb",
|
||||
"filesize": 1209543680,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "csr1000v-universalk9.03.17.00.S.156-1.S-ext.qcow2",
|
||||
"version": "3.17",
|
||||
"md5sum": "06cbfcd11f3557391db64fe2a6015a6e",
|
||||
"filesize": 1346305024,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "csr1000v-universalk9.16.3.1-build2.qcow2",
|
||||
"version": "16.3.1-build2",
|
||||
"md5sum": "a770e96de928265515304c9c9d6b46b9",
|
||||
"filesize": 1280835584,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "csr1000v-universalk9.16.03.01.qcow2",
|
||||
@@ -162,21 +162,21 @@
|
||||
"version": "16.3.2",
|
||||
"md5sum": "2e5803d23cd52cba5d55fa8306be5f13",
|
||||
"filesize": 1167720448,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "csr1000v-universalk9.16.4.1.qcow2",
|
||||
"version": "16.4.1",
|
||||
"md5sum": "3428e0dcf5132a1b11ab7696d8c61b2e",
|
||||
"filesize": 1261961216,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "csr1000v-universalk9.16.6.1.qcow2",
|
||||
"version": "16.6.1-VIRL",
|
||||
"md5sum": "996eb6dbf54781f6393bd689571a818c",
|
||||
"filesize": 1316301824,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -30,77 +30,77 @@
|
||||
"version": "15.9(3)M9",
|
||||
"md5sum": "01b707a2e33185d6d33e0255ced45d23",
|
||||
"filesize": 57323008,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.159-3.m8.qcow2",
|
||||
"version": "15.9(3)M8",
|
||||
"md5sum": "8d93a185c2fa778178a933f20b02150a",
|
||||
"filesize": 57319424,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.159-3.m6.qcow2",
|
||||
"version": "15.9(3)M6",
|
||||
"md5sum": "49a6977977263b2774bebc56e4e678ff",
|
||||
"filesize": 57309696,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.159-3.m4.qcow2",
|
||||
"version": "15.9(3)M4",
|
||||
"md5sum": "355b13ab821e64e2939fd7008d6304d7",
|
||||
"filesize": 57297920,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.159-3.m3.qcow2",
|
||||
"version": "15.9(3)M3",
|
||||
"md5sum": "12893843af18e4c62f13d07266755653",
|
||||
"filesize": 57296384,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.159-3.m2.qcow2",
|
||||
"version": "15.9(3)M2",
|
||||
"md5sum": "a19e998bc3086825c751d125af722329",
|
||||
"filesize": 57308672,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.spa.158-3.m2.qcow2",
|
||||
"version": "15.8(3)M2",
|
||||
"md5sum": "40e3d25b5b0cb13d639fcd2cf18e9965",
|
||||
"filesize": 57129984,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.vmdk.SPA.157-3.M3",
|
||||
"version": "15.7(3)M3",
|
||||
"md5sum": "37c148ffa14a82f418a6e9c2b049fafe",
|
||||
"filesize": 134021120,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.vmdk.SPA.156-2.T",
|
||||
"version": "15.6(2)T",
|
||||
"md5sum": "83707e3cc93646da58ee6563a68002b5",
|
||||
"filesize": 128450560,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.vmdk.SPA.156-1.T",
|
||||
"version": "15.6(1)T",
|
||||
"md5sum": "e7cb1bbd0c59280dd946feefa68fa270",
|
||||
"filesize": 128122880,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios-adventerprisek9-m.vmdk.SPA.155-3.M",
|
||||
"version": "15.5(3)M",
|
||||
"md5sum": "79f613ac3b179d5a64520730925130b2",
|
||||
"filesize": 127926272,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "IOSv_startup_config.img",
|
||||
|
||||
@@ -30,35 +30,35 @@
|
||||
"version": "15.2(20200924:215240)",
|
||||
"md5sum": "99ecab32de12410c533e6abd4e9710aa",
|
||||
"filesize": 90409984,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios_l2-adventerprisek9-m.ssa.high_iron_20190423.qcow2",
|
||||
"version": "15.2(6.0.81)E",
|
||||
"md5sum": "71cacb678f98a106f99e889b97b34686",
|
||||
"filesize": 44950016,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios_l2-adventerprisek9-m.SSA.high_iron_20180619.qcow2",
|
||||
"version": "15.2.1",
|
||||
"md5sum": "14b981002e40b660f2d7400401e04c14",
|
||||
"filesize": 44938752,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios_l2-adventerprisek9-m.03.2017.qcow2",
|
||||
"version": "15.2(20170321:233949)",
|
||||
"md5sum": "8f14b50083a14688dec2fc791706bb3e",
|
||||
"filesize": 41157632,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "vios_l2-adventerprisek9-m.vmdk.SSA.152-4.0.55.E",
|
||||
"version": "15.2(4.0.55)E",
|
||||
"md5sum": "1a3a21f5697cae64bb930895b986d71e",
|
||||
"filesize": 96862208,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -30,14 +30,14 @@
|
||||
"version": "6.1.3",
|
||||
"md5sum": "1693b5d22a398587dd0fed2877d8dfac",
|
||||
"filesize": 428588544,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "iosxrv-k9-demo-6.0.1.qcow2",
|
||||
"version": "6.0.1",
|
||||
"md5sum": "0831ecf43628eccb752ebb275de9a62a",
|
||||
"filesize": 908132352,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -31,21 +31,21 @@
|
||||
"version": "24.3.1",
|
||||
"md5sum": "bd047c457e29952f265583f299bab845",
|
||||
"filesize": 1704658432,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "xrv9k-fullk9-x-7.7.1.qcow2",
|
||||
"version": "7.7.1",
|
||||
"md5sum": "682fff40d2ff373d8da3342906553b54",
|
||||
"filesize": 1643905024,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "xrv9k-fullk9-x-7.1.1.qcow2",
|
||||
"version": "7.1.1",
|
||||
"md5sum": "dcf241e3f8df0151fec2c7bfac9d96ac",
|
||||
"filesize": 1443758080,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -15,11 +15,17 @@
|
||||
"iou": {
|
||||
"ethernet_adapters": 4,
|
||||
"serial_adapters": 0,
|
||||
"nvram": 512,
|
||||
"ram": 512,
|
||||
"nvram": 256,
|
||||
"ram": 1024,
|
||||
"startup_config": "iou_l2_base_startup-config.txt"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "x86_64_crb_linux_l2-adventerprisek9-ms.17.16.1a.iol",
|
||||
"version": "17.16.1a",
|
||||
"md5sum": "d55879318e51c5401fb9314d45c67728",
|
||||
"filesize": 244265240
|
||||
},
|
||||
{
|
||||
"filename": "x86_64_crb_linux_l2-adventerprisek9-ms.iol",
|
||||
"version": "17.15.1",
|
||||
@@ -33,25 +39,25 @@
|
||||
"filesize": 240355720
|
||||
},
|
||||
{
|
||||
"filename": "i86bi-linux-l2-ipbasek9-15.1g.bin",
|
||||
"version": "15.1g",
|
||||
"md5sum": "0b8b9e14ca99b68c654e44c4296857ba",
|
||||
"filesize": 62137336
|
||||
"filename": "i86bi_linux_l2-adventerprisek9-ms.SSA.high_iron_20190423.bin",
|
||||
"version": "15.2(20190423)",
|
||||
"md5sum": "ffe884f8e762b762d7886c51d8ee015c",
|
||||
"filesize": 126249700
|
||||
},
|
||||
{
|
||||
"filename": "i86bi-linux-l2-adventerprisek9-15.1a.bin",
|
||||
"version": "15.1a",
|
||||
"md5sum": "9549a20a7391fb849da32caa77a0d254",
|
||||
"filesize": 72726092
|
||||
},
|
||||
{
|
||||
"filename": "i86bi-linux-l2-adventerprisek9-15.2d.bin",
|
||||
"version": "15.2d",
|
||||
"md5sum": "f16db44433beb3e8c828db5ddad1de8a",
|
||||
"filesize": 105036380
|
||||
"filename": "i86bi_LinuxL2-AdvEnterpriseK9-M_152_May_2018.bin",
|
||||
"version": "15.2(20180510)",
|
||||
"md5sum": "d704b68c5f4c4f92e56b754b49b92012",
|
||||
"filesize": 126226692
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "17.16.1a",
|
||||
"images": {
|
||||
"image": "x86_64_crb_linux_l2-adventerprisek9-ms.17.16.1a.iol"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "17.15.1",
|
||||
"images": {
|
||||
@@ -65,21 +71,15 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "15.1g",
|
||||
"name": "15.2(20190423)",
|
||||
"images": {
|
||||
"image": "i86bi-linux-l2-ipbasek9-15.1g.bin"
|
||||
"image": "i86bi_linux_l2-adventerprisek9-ms.SSA.high_iron_20190423.bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "15.1a",
|
||||
"name": "15.2(20180510)",
|
||||
"images": {
|
||||
"image": "i86bi-linux-l2-adventerprisek9-15.1a.bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "15.2d",
|
||||
"images": {
|
||||
"image": "i86bi-linux-l2-adventerprisek9-15.2d.bin"
|
||||
"image": "i86bi_LinuxL2-AdvEnterpriseK9-M_152_May_2018.bin"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
@@ -15,11 +15,17 @@
|
||||
"iou": {
|
||||
"ethernet_adapters": 2,
|
||||
"serial_adapters": 2,
|
||||
"nvram": 512,
|
||||
"ram": 512,
|
||||
"nvram": 256,
|
||||
"ram": 1024,
|
||||
"startup_config": "iou_l3_base_startup-config.txt"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "x86_64_crb_linux-adventerprisek9-ms.17.16.1a.iol",
|
||||
"version": "17.16.1a",
|
||||
"md5sum": "39bdf959c3b99a3c81d66451f1cf0404",
|
||||
"filesize": 293062920
|
||||
},
|
||||
{
|
||||
"filename": "x86_64_crb_linux-adventerprisek9-ms.iol",
|
||||
"version": "17.15.1",
|
||||
@@ -37,21 +43,15 @@
|
||||
"version": "15.7(3)M2",
|
||||
"md5sum": "d6874260c3daeeb96d10fc844ae0b93b",
|
||||
"filesize": 184759244
|
||||
},
|
||||
{
|
||||
"filename": "i86bi-linux-l3-adventerprisek9-ms.155-2.T.bin",
|
||||
"version": "155-2T",
|
||||
"md5sum": "45e99761a95cbd3ee3924ecf0f3d89e5",
|
||||
"filesize": 172982492
|
||||
},
|
||||
{
|
||||
"filename": "i86bi-linux-l3-adventerprisek9-15.4.1T.bin",
|
||||
"version": "15.4.1T",
|
||||
"md5sum": "2eabae17778316c49cbc80e8e81262f9",
|
||||
"filesize": 152677848
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "17.16.1a",
|
||||
"images": {
|
||||
"image": "x86_64_crb_linux-adventerprisek9-ms.17.16.1a.iol"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "17.15.1",
|
||||
"images": {
|
||||
@@ -69,18 +69,6 @@
|
||||
"images": {
|
||||
"image": "i86bi_LinuxL3-AdvEnterpriseK9-M2_157_3_May_2018.bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "155-2T",
|
||||
"images": {
|
||||
"image": "i86bi-linux-l3-adventerprisek9-ms.155-2.T.bin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "15.4.1T",
|
||||
"images": {
|
||||
"image": "i86bi-linux-l3-adventerprisek9-15.4.1T.bin"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -30,14 +30,14 @@
|
||||
"version": "7.3.0",
|
||||
"md5sum": "b4cd6edf15ab4c6bce53c3f6c1e3a742",
|
||||
"filesize": 214368256,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
},
|
||||
{
|
||||
"filename": "titanium-d1.7.2.0.D1.1.vmdk",
|
||||
"version": "7.2.0",
|
||||
"md5sum": "0ee38c7d717840cb4ca822f4870671d0",
|
||||
"filesize": 361103360,
|
||||
"download_url": "https://learningnetworkstore.cisco.com/myaccount"
|
||||
"download_url": "https://u.cisco.com/my-learning/my-account"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
"vendor_url": "https://www.extremenetworks.com",
|
||||
"documentation_url": "https://www.extremenetworks.com/support/documentation",
|
||||
"product_name": "EXOS VM",
|
||||
"registry_version": 4,
|
||||
"registry_version": 5,
|
||||
"status": "stable",
|
||||
"maintainer": "Extreme Networks",
|
||||
"maintainer_email": "GitHubscripting@extremenetworks.com",
|
||||
@@ -18,18 +18,25 @@
|
||||
"qemu": {
|
||||
"adapter_type": "rtl8139",
|
||||
"adapters": 13,
|
||||
"ram": 512,
|
||||
"ram": 1024,
|
||||
"hda_disk_interface": "ide",
|
||||
"arch": "x86_64",
|
||||
"console_type": "telnet",
|
||||
"boot_priority": "dc",
|
||||
"kvm": "allow",
|
||||
"options": "-cpu core2duo"
|
||||
"options": "-nographic -cpu host -enable-kvm"
|
||||
},
|
||||
|
||||
"images": [
|
||||
|
||||
{
|
||||
{
|
||||
"filename": "EXOS-VM_33.6.1.14.qcow2",
|
||||
"version": "33.6.1.14",
|
||||
"md5sum": "01ea4bea3f321f91910565bb223a2540",
|
||||
"filesize": 278647296,
|
||||
"direct_download_url": "https://akamai-ep.extremenetworks.com/Extreme_P/github-en/Virtual_EXOS/EXOS-VM_33.6.1.14.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "EXOS-VM_32.7.2.19.qcow2",
|
||||
"version": "32.7.2.19",
|
||||
"md5sum": "eba580a2e18d2a9cc972c9ece8917ea8",
|
||||
@@ -48,6 +55,12 @@
|
||||
|
||||
"versions": [
|
||||
|
||||
{
|
||||
"name": "33.6.1.14",
|
||||
"images": {
|
||||
"hda_disk_image": "EXOS-VM_33.6.1.14.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "32.7.2.19",
|
||||
"images": {
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
{
|
||||
"appliance_id": "4ac0d5bc-714d-4a5a-8af5-8fb452046acd",
|
||||
"name": "Home Assistant",
|
||||
"category": "guest",
|
||||
"description": "Open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts.",
|
||||
"vendor_name": "Open Home Foundation",
|
||||
"vendor_url": "https://www.openhomefoundation.org/",
|
||||
"vendor_logo_url": "https://www.openhomefoundation.org/assets/images/logo/open-home-foundation.svg",
|
||||
"documentation_url": "https://www.home-assistant.io/installation/alternative",
|
||||
"product_name": "haos",
|
||||
"product_url": "https://www.home-assistant.io/",
|
||||
"registry_version": 8,
|
||||
"status": "stable",
|
||||
"availability": "free",
|
||||
"maintainer": "Neyder Achahuanco Apaza",
|
||||
"maintainer_email": "gns3@neyder.net",
|
||||
"usage": "You will be able to reach Home Assistant on homeassistant.local:8123, you might need to access Home Assistant at homeassistant:8123 or http://X.X.X.X:8123 (replace X.X.X.X with your virtual machine\u2019s IP address).\nYou can access trough console with root user without password.",
|
||||
"symbol": "home-assistant-logomark-color-on-light.svg",
|
||||
"default_username": "cisco",
|
||||
"default_password": "admin",
|
||||
"settings": [
|
||||
{
|
||||
"name": "Default template settings",
|
||||
"default": true,
|
||||
"template_type": "qemu",
|
||||
"template_properties":
|
||||
{
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"platform": "x86_64",
|
||||
"adapters": 1,
|
||||
"ram": 2048,
|
||||
"cpus": 2,
|
||||
"hda_disk_interface": "virtio",
|
||||
"console_type": "telnet",
|
||||
"boot_priority": "cd",
|
||||
"on_close": "shutdown_signal",
|
||||
"uefi": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"images": [
|
||||
{
|
||||
"filename": "haos_ova-17.1.qcow2",
|
||||
"version": "17.1",
|
||||
"md5sum": "e1b950430045859a3ac035cb420df158",
|
||||
"filesize": 1024393216,
|
||||
"download_url": "https://www.home-assistant.io/installation/alternative",
|
||||
"direct_download_url": "https://github.com/home-assistant/operating-system/releases/download/17.1/haos_ova-17.1.qcow2.xz",
|
||||
"compression": "xz"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"images": {
|
||||
"hda_disk_image": "haos_ova-17.1.qcow2"
|
||||
},
|
||||
"name": "17.1"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -111,9 +111,51 @@
|
||||
"md5sum": "e2eb1a4fff9d56815f37c2e82a6279fb",
|
||||
"version": "25.11.0",
|
||||
"direct_download_url": "https://github.com/kernelkit/infix/releases/download/v25.11.0/infix-x86_64-disk-25.11.0.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "infix-x86_64-v26.01.0.qcow2",
|
||||
"filesize": 307363840,
|
||||
"md5sum": "bd3b9c56f98ba264c36e4d6f69931546",
|
||||
"version": "26.01.0",
|
||||
"direct_download_url": "https://github.com/kernelkit/infix/releases/download/v26.01.0/infix-x86_64-v26.01.0.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "infix-x86_64-v26.02.1.qcow2",
|
||||
"filesize": 316407808,
|
||||
"md5sum": "0c4da508cfcb702c066f47227644b65f",
|
||||
"version": "26.02.1",
|
||||
"direct_download_url": "https://github.com/kernelkit/infix/releases/download/v26.02.1/infix-x86_64-v26.02.1.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "infix-x86_64-v26.03.0.qcow2",
|
||||
"filesize": 320339968,
|
||||
"md5sum": "24cd1006734993dab338e5c75f80b875",
|
||||
"version": "26.03.0",
|
||||
"direct_download_url": "https://github.com/kernelkit/infix/releases/download/v26.03.0/infix-x86_64-v26.03.0.qcow2"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "26.03.0",
|
||||
"images": {
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "infix-x86_64-v26.03.0.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "26.02.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "infix-x86_64-v26.02.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "26.01.0",
|
||||
"images": {
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "infix-x86_64-v26.01.0.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "25.11.0",
|
||||
"images": {
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
"maintainer_email": "github@sugarpapa.mozmail.com",
|
||||
"usage": "GNS3 SHOULD be a baremetal installation. Using the GNS3 VM MIGHT result in unwanted issues. Default user is root. No password is needed.",
|
||||
"symbol": "juniper-vmx.svg",
|
||||
"first_port_name": "ge-0/0/0",
|
||||
"first_port_name": "fxp0",
|
||||
"port_name_format": "ge-0/0/{port0}",
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 17,
|
||||
"adapters": 11,
|
||||
"ram": 5120,
|
||||
"cpus": 4,
|
||||
"hda_disk_interface": "virtio",
|
||||
@@ -72,4 +72,4 @@
|
||||
"name": "23.2R1.15"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -27,6 +27,24 @@
|
||||
"options": "-nographic"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "chr-7.22.1.img",
|
||||
"version": "7.22.1",
|
||||
"md5sum": "a67290634f489071eae2fd99dcadba86",
|
||||
"filesize": 134217728,
|
||||
"download_url": "http://www.mikrotik.com/download",
|
||||
"direct_download_url": "https://download.mikrotik.com/routeros/7.22.1/chr-7.22.1.img.zip",
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
"filename": "chr-7.20.8.img",
|
||||
"version": "7.20.8",
|
||||
"md5sum": "a432cf89f405115163952eefd82934e4",
|
||||
"filesize": 134217728,
|
||||
"download_url": "http://www.mikrotik.com/download",
|
||||
"direct_download_url": "https://download.mikrotik.com/routeros/7.20.8/chr-7.20.8.img.zip",
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
"filename": "chr-7.16.img",
|
||||
"version": "7.16",
|
||||
@@ -74,6 +92,18 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "7.22.1",
|
||||
"images": {
|
||||
"hda_disk_image": "chr-7.22.1.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.20.8",
|
||||
"images": {
|
||||
"hda_disk_image": "chr-7.20.8.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.16",
|
||||
"images": {
|
||||
|
||||
@@ -23,6 +23,15 @@
|
||||
"kvm": "allow"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "openwrt-25.12.0-x86-64-generic-ext4-combined.img",
|
||||
"version": "25.12.0",
|
||||
"md5sum": "8c0e01307fc47c1f862a5d0c9a51c2c5",
|
||||
"filesize": 126353408,
|
||||
"download_url": "https://downloads.openwrt.org/releases/25.12.0/targets/x86/64/",
|
||||
"direct_download_url": "https://downloads.openwrt.org/releases/25.12.0/targets/x86/64/openwrt-25.12.0-x86-64-generic-ext4-combined.img.gz",
|
||||
"compression": "gzip"
|
||||
},
|
||||
{
|
||||
"filename": "openwrt-24.10.2-x86-64-generic-ext4-combined.img",
|
||||
"version": "24.10.2",
|
||||
@@ -232,6 +241,12 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "25.12.0",
|
||||
"images": {
|
||||
"hda_disk_image": "openwrt-25.12.0-x86-64-generic-ext4-combined.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "24.10.2",
|
||||
"images": {
|
||||
|
||||
@@ -25,6 +25,15 @@
|
||||
"kvm": "require"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "OPNsense-26.1-nano-amd64.img",
|
||||
"version": "26.1",
|
||||
"md5sum": "3b774e8fb651a5d00aa6fa3e0d1b1ff0",
|
||||
"filesize": 3221225472,
|
||||
"download_url": "https://opnsense.c0urier.net/releases/26.1/",
|
||||
"direct_download_url": "https://opnsense.c0urier.net/releases/26.1/OPNsense-26.1-nano-amd64.img.bz2",
|
||||
"compression": "bzip2"
|
||||
},
|
||||
{
|
||||
"filename": "OPNsense-25.7-nano-amd64.img",
|
||||
"version": "25.7",
|
||||
@@ -90,6 +99,24 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "26.1",
|
||||
"images": {
|
||||
"hda_disk_image": "OPNsense-26.1-nano-amd64.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "25.7",
|
||||
"images": {
|
||||
"hda_disk_image": "OPNsense-25.7-nano-amd64.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "25.1",
|
||||
"images": {
|
||||
"hda_disk_image": "OPNsense-25.1-nano-amd64.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "24.7",
|
||||
"images": {
|
||||
|
||||
@@ -13,11 +13,11 @@
|
||||
"availability": "service-contract",
|
||||
"maintainer": "Da-Geek",
|
||||
"maintainer_email": "dageek@dageeks-geeks.gg",
|
||||
"usage": "You should download Red Hat Enterprise Linux KVM Guest Image from https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.5/x86_64/product-software attach/customize rhel-cloud-init.iso and start.\nusername: cloud-user\npassword: redhat",
|
||||
"usage": "You should download Red Hat Enterprise Linux KVM Guest Image from https://access.redhat.com/downloads/content/rhel attach/customize rhel-cloud-init.iso and start.\nusername: cloud-user\npassword: redhat",
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 1,
|
||||
"ram": 1024,
|
||||
"ram": 1536,
|
||||
"hda_disk_interface": "virtio",
|
||||
"arch": "x86_64",
|
||||
"console_type": "telnet",
|
||||
@@ -27,11 +27,32 @@
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "rhel-9.5-x86_64-kvm.qcow2",
|
||||
"version": "9.5",
|
||||
"md5sum": "8174396d5cb47727c59dd04dd9a05418",
|
||||
"filesize": 974389248,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.5/x86_64/product-software"
|
||||
"filename": "rhel-10.1-x86_64-kvm.qcow2",
|
||||
"version": "10.1",
|
||||
"md5sum": "b2f35b1ac0600de31cadf30a622a2fef",
|
||||
"filesize": 1010827264,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---10/10.1/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-10.0-x86_64-kvm.qcow2",
|
||||
"version": "10.0",
|
||||
"md5sum": "ea5918fa116ec53f9ef1ce4be69ae2be",
|
||||
"filesize": 855506944,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---10/10.0/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-9.7-x86_64-kvm.qcow2",
|
||||
"version": "9.7",
|
||||
"md5sum": "abc2f42cc5daeea6b03d0d2d478a0d1c",
|
||||
"filesize": 1229979648,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.7/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-9.6-x86_64-kvm.qcow2",
|
||||
"version": "9.6",
|
||||
"md5sum": "056648d716275053ebe77b1d4f68c862",
|
||||
"filesize": 1060438016,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.6/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-9.4-x86_64-kvm.qcow2",
|
||||
@@ -40,34 +61,6 @@
|
||||
"filesize": 957218816,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.4/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-9.3-x86_64-kvm.qcow2",
|
||||
"version": "9.3",
|
||||
"md5sum": "409d8d15f5177db2617b0e3e02139b5c",
|
||||
"filesize": 858193920,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---9/9.3/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-9.2-x86_64-kvm.qcow2",
|
||||
"version": "9.2",
|
||||
"md5sum": "f33845298b387dbcfbf162c6b4e3f8c8",
|
||||
"filesize": 819265536,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/9.2/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-baseos-9.1-x86_64-kvm.qcow2",
|
||||
"version": "9.1",
|
||||
"md5sum": "622de743da83bcec1ad2959ecaedb8f4",
|
||||
"filesize": 753401856,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/9.1/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-baseos-9.0-x86_64-kvm.qcow2",
|
||||
"version": "9.0",
|
||||
"md5sum": "4a41497d354fe99a4abf55f1ed73edcb",
|
||||
"filesize": 696582144,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/9.0/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.10-x86_64-kvm.qcow2",
|
||||
"version": "8.10",
|
||||
@@ -75,13 +68,6 @@
|
||||
"filesize": 1065091072,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.10/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.9-x86_64-kvm.qcow2",
|
||||
"version": "8.9",
|
||||
"md5sum": "23295fe508678cbdebfbdbd41ef6e6e2",
|
||||
"filesize": 971833344,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.9/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.8-x86_64-kvm.qcow2",
|
||||
"version": "8.8",
|
||||
@@ -89,13 +75,6 @@
|
||||
"filesize": 926810112,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.8/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.7-x86_64-kvm.qcow2",
|
||||
"version": "8.7",
|
||||
"md5sum": "ab71a2c4cc276441bf999f531e064507",
|
||||
"filesize": 858128384,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.7/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.6-x86_64-kvm.qcow2",
|
||||
"version": "8.6",
|
||||
@@ -104,31 +83,10 @@
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.6/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.5-x86_64-kvm.qcow2",
|
||||
"version": "8.5",
|
||||
"md5sum": "1efb78dbb2033ba4ac6589a06c95c2d4",
|
||||
"filesize": 779419648,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.5/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.4-x86_64-kvm.qcow2",
|
||||
"version": "8.4",
|
||||
"md5sum": "db4c3a72857b784dc6e96120351f2894",
|
||||
"filesize": 727449600,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.4/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-8.3-x86_64-kvm.qcow2",
|
||||
"version": "8.3",
|
||||
"md5sum": "dd554c059e0910379fff88f677f4a4b3",
|
||||
"filesize": 1316683776,
|
||||
"download_url": "https://access.redhat.com/downloads/content/479/ver=/rhel---8/8.3/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
"filename": "rhel-server-7.9-x86_64-kvm.qcow2",
|
||||
"filename": "rhel-server-7.9-update-12-x86_64-kvm.qcow2",
|
||||
"version": "7.9",
|
||||
"md5sum": "8d6669b3e2bb8df15b9b4280936cf950",
|
||||
"filesize": 827777024,
|
||||
"md5sum": "f77fc7e3cf31a210a8244e486466ce34",
|
||||
"filesize": 838036992,
|
||||
"download_url": "https://access.redhat.com/downloads/content/69/ver=/rhel---7/7.9/x86_64/product-software"
|
||||
},
|
||||
{
|
||||
@@ -140,17 +98,39 @@
|
||||
},
|
||||
{
|
||||
"filename": "rhel-cloud-init.iso",
|
||||
"version": "1.0",
|
||||
"md5sum": "421745b0d13615ecd48696f98d8b6352",
|
||||
"version": "1.1",
|
||||
"md5sum": "f1f908d36e67f843dd94db1c2e8c8373",
|
||||
"filesize": 374784,
|
||||
"download_url": "https://gitlab.com/neyder/rhel-cloud-init/raw/master/rhel-cloud-init.iso"
|
||||
"download_url": "https://github.com/GNS3/gns3-registry/tree/master/cloud-init/rhel",
|
||||
"direct_download_url": "https://github.com/GNS3/gns3-registry/raw/master/cloud-init/rhel/rhel-cloud-init.iso"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "9.5",
|
||||
"name": "10.1",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-9.5-x86_64-kvm.qcow2",
|
||||
"hda_disk_image": "rhel-10.1-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "10.0",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-10.0-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.7",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-9.7-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.6",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-9.6-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
@@ -161,34 +141,6 @@
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.3",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-9.3-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.2",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-9.2-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.1",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-baseos-9.1-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.0",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-baseos-9.0-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.10",
|
||||
"images": {
|
||||
@@ -196,13 +148,6 @@
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.9",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-8.9-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.8",
|
||||
"images": {
|
||||
@@ -210,13 +155,6 @@
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.7",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-8.7-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.6",
|
||||
"images": {
|
||||
@@ -224,31 +162,10 @@
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.5",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-8.5-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.4",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-8.4-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "8.3",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-8.3-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.9",
|
||||
"images": {
|
||||
"hda_disk_image": "rhel-server-7.9-x86_64-kvm.qcow2",
|
||||
"hda_disk_image": "rhel-server-7.9-update-12-x86_64-kvm.qcow2",
|
||||
"cdrom_image": "rhel-cloud-init.iso"
|
||||
}
|
||||
},
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"appliance_id": "ed6b9f98-7de2-4d61-a3ed-ad4c3e323ace",
|
||||
"name": "Tiny Core Linux",
|
||||
"category": "guest",
|
||||
"description": "Core Linux is a smaller variant of Tiny Core without a graphical desktop.\n\nIt provides a complete Linux system using only a few MiB.",
|
||||
"description": "TinyCore is a Linux system with a graphical desktop using only a few MiB.",
|
||||
"vendor_name": "Team Tiny Core",
|
||||
"vendor_url": "http://distro.ibiblio.org/tinycorelinux",
|
||||
"documentation_url": "http://wiki.tinycorelinux.net/",
|
||||
@@ -25,6 +25,14 @@
|
||||
"options": "-vga std -usbdevice tablet"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "linux-tinycore-17.0.qcow2",
|
||||
"version": "17.0",
|
||||
"md5sum": "6434d4da25dd0277cc90b000bb4ac8f1",
|
||||
"filesize": 35061760,
|
||||
"download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/",
|
||||
"direct_download_url": "http://downloads.sourceforge.net/project/gns-3/Qemu%20Appliances/linux-tinycore-17.0.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "linux-tinycore-11.1.qcow2",
|
||||
"version": "11.1",
|
||||
@@ -51,6 +59,12 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "17.0",
|
||||
"images": {
|
||||
"hda_disk_image": "linux-tinycore-17.0.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "11.1",
|
||||
"images": {
|
||||
|
||||
@@ -9,27 +9,54 @@
|
||||
"documentation_url": "https://docs.vyos.io/",
|
||||
"product_name": "VyOS Universal Router",
|
||||
"product_url": "https://vyos.io/vyos-universal-router",
|
||||
"registry_version": 4,
|
||||
"registry_version": 8,
|
||||
"status": "stable",
|
||||
"availability": "service-contract",
|
||||
"maintainer": "VyOS Inc.",
|
||||
"maintainer_email": "support@vyos.io",
|
||||
"usage": "\nDefault credentials:\nUser: vyos\nPassword: vyos",
|
||||
"installation_instructions": "To install the appliance, you must:\n\n1. Have an active VyOS subscription (for details, visit https://vyos.io/).\n2. Download the QEMU/KVM image for your target version from the support portal: https://support.vyos.io/.\n3. Import the downloaded image for installation in the next step.\n\nAlternatively, you can:\n- Build your own image, or\n- Use any compatible qcow2 images (including rolling or stream releases) by selecting \"Create a new version\" and enabling the \"Allow custom files\" feature.",
|
||||
"usage": "No extra installation steps are required - simply boot the router.\nFor more details, please refer to the documentation: https://docs.vyos.io/",
|
||||
"default_username": "vyos",
|
||||
"default_password": "vyos",
|
||||
"symbol": "vyos.svg",
|
||||
"port_name_format": "eth{0}",
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 10,
|
||||
"ram": 2048,
|
||||
"cpus": 4,
|
||||
"hda_disk_interface": "virtio",
|
||||
"arch": "x86_64",
|
||||
"console_type": "telnet",
|
||||
"boot_priority": "c",
|
||||
"kvm": "require",
|
||||
"on_close": "shutdown_signal"
|
||||
},
|
||||
"settings": [
|
||||
{
|
||||
"name": "default x86_64",
|
||||
"default": true,
|
||||
"template_type": "qemu",
|
||||
"template_properties": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 10,
|
||||
"port_name_format": "eth{0}",
|
||||
"ram": 2048,
|
||||
"cpus": 4,
|
||||
"hda_disk_interface": "virtio",
|
||||
"platform": "x86_64",
|
||||
"console_type": "telnet",
|
||||
"boot_priority": "c",
|
||||
"options": "-cpu host",
|
||||
"uefi": false,
|
||||
"on_close": "shutdown_signal"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "1.5 x86_64",
|
||||
"inherit_default_properties": true,
|
||||
"template_type": "qemu",
|
||||
"template_properties": {
|
||||
"ram": 8192,
|
||||
"cpus": 4
|
||||
}
|
||||
}
|
||||
],
|
||||
"images": [
|
||||
{
|
||||
"filename": "vyos-1.5.0-kvm-amd64.qcow2",
|
||||
"version": "1.5.0",
|
||||
"md5sum": "f84587bd6c45b139563a1d1d2fe0b2e8",
|
||||
"filesize": 618528768,
|
||||
"download_url": "https://support.vyos.io/"
|
||||
},
|
||||
{
|
||||
"filename": "vyos-1.4.4-kvm-amd64.qcow2",
|
||||
"version": "1.4.4",
|
||||
@@ -132,11 +159,18 @@
|
||||
"filename": "vyos-1.2.5-amd64.qcow2",
|
||||
"version": "1.2.5",
|
||||
"md5sum": "110c22309ec480600446fd2fb4f27a0d",
|
||||
"filesize": 411500544 ,
|
||||
"filesize": 411500544,
|
||||
"download_url": "https://support.vyos.io/"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "1.5.0",
|
||||
"settings": "1.5 x86_64",
|
||||
"images": {
|
||||
"hda_disk_image": "vyos-1.5.0-kvm-amd64.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "1.4.4",
|
||||
"images": {
|
||||
|
||||
@@ -30,19 +30,11 @@
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "WinDev2308Eval-disk1.vmdk",
|
||||
"version": "2308",
|
||||
"md5sum": "6a9b4ed6d7481f7bbf8a054c797b1eee",
|
||||
"filesize": 24945341952,
|
||||
"download_url": "https://download.microsoft.com/download/7/1/3/7135f2ab-8528-49fc-9252-8d5d94c697ef/WinDev2308Eval.VMWare.zip",
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
"filename": "WinDev2212Eval-disk1.vmdk",
|
||||
"version": "2212",
|
||||
"md5sum": "c79f393a067b92e01a513a118d455ac8",
|
||||
"filesize": 24620493824,
|
||||
"download_url": "https://aka.ms/windev_VM_vmware",
|
||||
"filename": "WinDev2407Eval-disk1.vmdk",
|
||||
"version": "2407",
|
||||
"md5sum": "66e7233c7922ef128c5b7c957d20bcbe",
|
||||
"filesize": 25984826368,
|
||||
"download_url": "https://download.microsoft.com/download/e/e/c/eec4775f-f2e8-4476-98b2-ca51502a6429/WinDev2407Eval.VMWare.zip",
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
@@ -57,17 +49,10 @@
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "2308",
|
||||
"name": "2407",
|
||||
"images": {
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "WinDev2308Eval-disk1.vmdk"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "2212",
|
||||
"images": {
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "WinDev2212Eval-disk1.vmdk"
|
||||
"hda_disk_image": "WinDev2407Eval-disk1.vmdk"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
@@ -312,8 +312,10 @@ class BaseNode:
|
||||
Stop the node process.
|
||||
"""
|
||||
|
||||
await self.stop_wrap_console()
|
||||
self.status = "stopped"
|
||||
try:
|
||||
await self.stop_wrap_console()
|
||||
finally:
|
||||
self.status = "stopped"
|
||||
|
||||
def suspend(self):
|
||||
"""
|
||||
|
||||
@@ -79,8 +79,10 @@ class Docker(BaseManager):
|
||||
stderr=asyncio.subprocess.DEVNULL
|
||||
)
|
||||
stdout, _ = await proc.communicate()
|
||||
if proc.returncode == 1:
|
||||
if proc.returncode == 1 or "static" in busybox_exec:
|
||||
# ldd returns 1 if the file is not a dynamic executable
|
||||
# on Alpine/musl, ldd returns 0 even for static binaries,
|
||||
# so also trust binaries named busybox-static or busybox.static
|
||||
log.info(f"Installing busybox from '{busybox_path}' to '{dst_busybox}'")
|
||||
shutil.copy2(busybox_path, dst_busybox, follow_symlinks=True)
|
||||
return
|
||||
|
||||
@@ -87,11 +87,11 @@ class IOUVM(BaseNode):
|
||||
self._serial_adapters = []
|
||||
self.ethernet_adapters = 2 # one adapter = 4 interfaces
|
||||
self.serial_adapters = 2 # one adapter = 4 interfaces
|
||||
self._use_default_iou_values = True # for RAM & NVRAM values
|
||||
self._nvram = 128 # Kilobytes
|
||||
self._use_default_iou_values = False # for RAM & NVRAM values
|
||||
self._nvram = 256 # Kilobytes
|
||||
self._startup_config = ""
|
||||
self._private_config = ""
|
||||
self._ram = 256 # Megabytes
|
||||
self._ram = 1024 # Megabytes
|
||||
self._application_id = application_id
|
||||
self._l1_keepalives = False # used to overcome the always-up Ethernet interfaces (not supported by all IOSes).
|
||||
|
||||
|
||||
@@ -2190,14 +2190,31 @@ class QemuVM(BaseNode):
|
||||
patched_qemu = True
|
||||
|
||||
# Each 32 PCI device we need to add a PCI bridge with max 9 bridges
|
||||
pci_devices = 4 + len(self._ethernet_adapters) # 4 PCI devices are use by default by qemu
|
||||
# Count PCI devices: 4 default + disks (virtio/sata/nvme/scsi) + network adapters
|
||||
pci_disk_devices = 0
|
||||
for drive in ["a", "b", "c", "d"]:
|
||||
# config disk replaces hdd when enabled
|
||||
if drive == "d" and self._create_config_disk:
|
||||
continue
|
||||
if getattr(self, "_hd{}_disk_image".format(drive)):
|
||||
interface = getattr(self, "_hd{}_disk_interface".format(drive))
|
||||
# virtio, sata, nvme, and scsi each consume 1 PCI slot; ide and none don't
|
||||
if interface not in ("none", "ide"):
|
||||
pci_disk_devices += 1
|
||||
# config disk (replaces hdd) also consumes a PCI slot if created
|
||||
if self._create_config_disk and self.config_disk_image:
|
||||
interface = self.hdd_disk_interface if self.hdd_disk_interface != "none" else self.hda_disk_interface
|
||||
if interface not in ("none", "ide"):
|
||||
pci_disk_devices += 1
|
||||
|
||||
pci_devices = 4 + pci_disk_devices + len(self._ethernet_adapters)
|
||||
pci_bridges = math.floor(pci_devices / 32)
|
||||
pci_bridges_created = 0
|
||||
if pci_bridges >= 1:
|
||||
if self._qemu_version and parse_version(self._qemu_version) < parse_version("2.4.0"):
|
||||
raise QemuError("Qemu version 2.4 or later is required to run this VM with a large number of network adapters")
|
||||
|
||||
pci_device_id = 4 + pci_bridges # Bridge consume PCI ports
|
||||
pci_device_id = 4 + pci_bridges + pci_disk_devices # Bridges and disks consume PCI ports
|
||||
for adapter_number, adapter in enumerate(self._ethernet_adapters):
|
||||
mac = int_to_macaddress(macaddress_to_int(self._mac_address) + adapter_number)
|
||||
|
||||
|
||||
@@ -217,7 +217,7 @@ class Controller:
|
||||
try:
|
||||
os.makedirs(os.path.dirname(self._config_file), exist_ok=True)
|
||||
with open(self._config_file, 'w+') as f:
|
||||
json.dump(controller_settings, f, indent=4)
|
||||
json.dump(controller_settings, f, indent=4, sort_keys=True)
|
||||
except OSError as e:
|
||||
log.error("Cannot write controller configuration file '{}': {}".format(self._config_file, e))
|
||||
|
||||
|
||||
@@ -32,7 +32,16 @@ log = logging.getLogger(__name__)
|
||||
CHUNK_SIZE = 1024 * 8 # 8KB
|
||||
|
||||
|
||||
async def export_project(zstream, project, temporary_dir, include_images=False, include_snapshots=False, keep_compute_ids=False, allow_all_nodes=False, reset_mac_addresses=False):
|
||||
async def export_project(
|
||||
zstream,
|
||||
project,
|
||||
temporary_dir,
|
||||
include_images=False,
|
||||
include_snapshots=False,
|
||||
keep_compute_ids=False,
|
||||
allow_all_nodes=False,
|
||||
reset_mac_addresses=False
|
||||
):
|
||||
"""
|
||||
Export a project to a zip file.
|
||||
|
||||
@@ -46,7 +55,7 @@ async def export_project(zstream, project, temporary_dir, include_images=False,
|
||||
:param include_snapshots: save snapshots to the zip file
|
||||
:param keep_compute_ids: If false replace all compute IDs y local (standard behavior for .gns3project to make it portable)
|
||||
:param allow_all_nodes: Allow all nodes type to be included in the zip even if not portable
|
||||
:param reset_mac_addresses: Reset MAC addresses for each node.
|
||||
:param reset_mac_addresses: Reset MAC addresses for each node
|
||||
"""
|
||||
|
||||
# To avoid issue with data not saved we disallow the export of a running project
|
||||
@@ -62,7 +71,16 @@ async def export_project(zstream, project, temporary_dir, include_images=False,
|
||||
# First we process the .gns3 in order to be sure we don't have an error
|
||||
for file in os.listdir(project._path):
|
||||
if file.endswith(".gns3"):
|
||||
await _patch_project_file(project, os.path.join(project._path, file), zstream, include_images, keep_compute_ids, allow_all_nodes, temporary_dir, reset_mac_addresses)
|
||||
await _patch_project_file(
|
||||
project,
|
||||
os.path.join(project._path, file),
|
||||
zstream,
|
||||
include_images,
|
||||
keep_compute_ids,
|
||||
allow_all_nodes,
|
||||
temporary_dir,
|
||||
reset_mac_addresses
|
||||
)
|
||||
|
||||
# Export the local files
|
||||
for root, dirs, files in os.walk(project._path, topdown=True, followlinks=False):
|
||||
@@ -87,6 +105,10 @@ async def export_project(zstream, project, temporary_dir, include_images=False,
|
||||
# save empty directories
|
||||
for directory in dirs:
|
||||
path = os.path.join(root, directory)
|
||||
if path == temporary_dir:
|
||||
continue
|
||||
if include_snapshots is False and path.endswith("snapshots"):
|
||||
continue
|
||||
if not os.listdir(path):
|
||||
zstream.write(path, os.path.relpath(path, project._path))
|
||||
except FileNotFoundError as e:
|
||||
@@ -142,7 +164,7 @@ def _is_exportable(path, include_snapshots=False):
|
||||
"""
|
||||
|
||||
# do not export snapshots by default
|
||||
if include_snapshots is False and path.endswith("snapshots"):
|
||||
if include_snapshots is False and os.path.dirname(path).endswith("snapshots"):
|
||||
return False
|
||||
|
||||
# do not export directories of snapshots
|
||||
@@ -167,7 +189,16 @@ def _is_exportable(path, include_snapshots=False):
|
||||
return True
|
||||
|
||||
|
||||
async def _patch_project_file(project, path, zstream, include_images, keep_compute_ids, allow_all_nodes, temporary_dir, reset_mac_addresses):
|
||||
async def _patch_project_file(
|
||||
project,
|
||||
path,
|
||||
zstream,
|
||||
include_images,
|
||||
keep_compute_ids,
|
||||
allow_all_nodes,
|
||||
temporary_dir,
|
||||
reset_mac_addresses
|
||||
):
|
||||
"""
|
||||
Patch a project file (.gns3) to export a project.
|
||||
The .gns3 file is renamed to project.gns3
|
||||
@@ -240,7 +271,7 @@ async def _patch_project_file(project, path, zstream, include_images, keep_compu
|
||||
for compute_id, image_type, image in remote_images:
|
||||
await _export_remote_images(project, compute_id, image_type, image, zstream, temporary_dir)
|
||||
|
||||
zstream.writestr("project.gns3", json.dumps(topology).encode())
|
||||
zstream.writestr("project.gns3", json.dumps(topology, indent=4, sort_keys=True).encode())
|
||||
return images
|
||||
|
||||
|
||||
|
||||
@@ -39,8 +39,18 @@ Handle the import of project from a .gns3project
|
||||
"""
|
||||
|
||||
|
||||
async def import_project(controller, project_id, stream, location=None, name=None, keep_compute_ids=False,
|
||||
auto_start=False, auto_open=False, auto_close=True):
|
||||
async def import_project(
|
||||
controller,
|
||||
project_id,
|
||||
stream,
|
||||
location=None,
|
||||
name=None,
|
||||
reset_mac_addresses=False,
|
||||
keep_compute_ids=False,
|
||||
auto_start=False,
|
||||
auto_open=False,
|
||||
auto_close=True,
|
||||
):
|
||||
"""
|
||||
Import a project contain in a zip file
|
||||
|
||||
@@ -51,7 +61,9 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
:param stream: A io.BytesIO of the zipfile
|
||||
:param location: Directory for the project if None put in the default directory
|
||||
:param name: Wanted project name, generate one from the .gns3 if None
|
||||
:param reset_mac_addresses: Reset MAC addresses for each node
|
||||
:param keep_compute_ids: keep compute IDs unchanged
|
||||
:param project_name: Original project name when restoring a snapshot
|
||||
|
||||
:returns: Project
|
||||
"""
|
||||
@@ -72,12 +84,14 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
# We import the project on top of an existing project (snapshots)
|
||||
if topology["project_id"] == project_id:
|
||||
project_name = topology["name"]
|
||||
restoring_snapshot = True
|
||||
else:
|
||||
# If the project name is already used we generate a new one
|
||||
if name:
|
||||
project_name = controller.get_free_project_name(name)
|
||||
else:
|
||||
project_name = controller.get_free_project_name(topology["name"])
|
||||
restoring_snapshot = False
|
||||
except (ValueError, KeyError):
|
||||
raise aiohttp.web.HTTPConflict(text="Cannot import project, the project.gns3 file is corrupted")
|
||||
|
||||
@@ -105,27 +119,11 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
topology["auto_open"] = auto_open
|
||||
topology["auto_close"] = auto_close
|
||||
|
||||
# Generate a new node id
|
||||
node_old_to_new = {}
|
||||
for node in topology["topology"]["nodes"]:
|
||||
if "node_id" in node:
|
||||
node_old_to_new[node["node_id"]] = str(uuid.uuid4())
|
||||
_move_node_file(path, node["node_id"], node_old_to_new[node["node_id"]])
|
||||
node["node_id"] = node_old_to_new[node["node_id"]]
|
||||
else:
|
||||
node["node_id"] = str(uuid.uuid4())
|
||||
if not restoring_snapshot:
|
||||
# Do not re-generate IDs if we are restoring a snapshot because they should be the same in a project
|
||||
regenerate_topology_ids(topology, path, reset_mac_addresses=reset_mac_addresses)
|
||||
|
||||
# Update link to use new id
|
||||
for link in topology["topology"]["links"]:
|
||||
link["link_id"] = str(uuid.uuid4())
|
||||
for node in link["nodes"]:
|
||||
node["node_id"] = node_old_to_new[node["node_id"]]
|
||||
|
||||
# Generate new drawings id
|
||||
for drawing in topology["topology"]["drawings"]:
|
||||
drawing["drawing_id"] = str(uuid.uuid4())
|
||||
|
||||
# Modify the compute id of the node depending of compute capacity
|
||||
# Modify the compute id of the node depending on compute capacity
|
||||
if not keep_compute_ids:
|
||||
# For some VM type we move them to the GNS3 VM if possible
|
||||
# unless it's a linux host without GNS3 VM
|
||||
@@ -135,14 +133,6 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
node["compute_id"] = "vm"
|
||||
else:
|
||||
# Round-robin through available compute resources.
|
||||
# computes = []
|
||||
# for compute_id in controller.computes:
|
||||
# compute = controller.get_compute(compute_id)
|
||||
# # only use the local compute or any connected compute
|
||||
# if compute_id == "local" or compute.connected:
|
||||
# computes.append(compute_id)
|
||||
# else:
|
||||
# log.warning(compute.name, "is not connected!")
|
||||
compute_nodes = itertools.cycle(controller.computes)
|
||||
for node in topology["topology"]["nodes"]:
|
||||
node["compute_id"] = next(compute_nodes)
|
||||
@@ -162,7 +152,7 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
# We change the project_id to avoid erasing the project
|
||||
topology["project_id"] = project_id
|
||||
with open(dot_gns3_path, "w+") as f:
|
||||
json.dump(topology, f, indent=4)
|
||||
json.dump(topology, f, indent=4, sort_keys=True)
|
||||
os.remove(os.path.join(path, "project.gns3"))
|
||||
|
||||
images_path = os.path.join(path, "images")
|
||||
@@ -170,8 +160,8 @@ async def import_project(controller, project_id, stream, location=None, name=Non
|
||||
await _import_images(controller, images_path)
|
||||
|
||||
snapshots_path = os.path.join(path, "snapshots")
|
||||
if os.path.exists(snapshots_path):
|
||||
await _import_snapshots(snapshots_path, project_name, project_id)
|
||||
if not restoring_snapshot and os.path.exists(snapshots_path):
|
||||
await update_snapshots(snapshots_path, path, project_name, project_id, reset_mac_addresses=reset_mac_addresses)
|
||||
|
||||
project = await controller.load_project(dot_gns3_path, load=False)
|
||||
return project
|
||||
@@ -195,6 +185,41 @@ def _create_symbolic_links(zip_file, path):
|
||||
except OSError as e:
|
||||
raise aiohttp.web.HTTPConflict(text=f"Cannot create symbolic link: {e}")
|
||||
|
||||
def regenerate_topology_ids(topology, new_project_path, reset_mac_addresses=False):
|
||||
"""
|
||||
Regenerate IDs in the topology and move the files of the nodes to match the new IDs.
|
||||
This is necessary because IDs must be unique across projects.
|
||||
|
||||
:param topology: topology content
|
||||
:param new_project_path: new project path
|
||||
:param reset_mac_addresses: reset MAC addresses
|
||||
"""
|
||||
|
||||
# Generate new node IDs
|
||||
node_old_to_new = {}
|
||||
for node in topology["topology"]["nodes"]:
|
||||
new_node_id = str(uuid.uuid4())
|
||||
if "node_id" in node:
|
||||
node_old_to_new[node["node_id"]] = new_node_id
|
||||
_move_node_file(new_project_path, node["node_id"], new_node_id)
|
||||
node["node_id"] = new_node_id
|
||||
if reset_mac_addresses:
|
||||
if "properties" in node:
|
||||
for prop, value in node["properties"].items():
|
||||
# reset the MAC address
|
||||
if prop in ("mac_addr", "mac_address"):
|
||||
node["properties"][prop] = None
|
||||
|
||||
# Generate new link IDs
|
||||
for link in topology["topology"]["links"]:
|
||||
link["link_id"] = str(uuid.uuid4())
|
||||
for node in link["nodes"]:
|
||||
node["node_id"] = node_old_to_new[node["node_id"]]
|
||||
|
||||
# Generate new drawings IDs
|
||||
for drawing in topology["topology"]["drawings"]:
|
||||
drawing["drawing_id"] = str(uuid.uuid4())
|
||||
|
||||
def _move_node_file(path, old_id, new_id):
|
||||
"""
|
||||
Move a file from a node when changing its id
|
||||
@@ -261,16 +286,17 @@ async def _import_images(controller, images_path):
|
||||
await wait_run_in_executor(shutil.move, path, dst)
|
||||
|
||||
|
||||
async def _import_snapshots(snapshots_path, project_name, project_id):
|
||||
async def update_snapshots(snapshots_dir, project_path, project_name, project_id, reset_mac_addresses=True):
|
||||
"""
|
||||
Import the snapshots and update their project name and ID to be the same as the main project.
|
||||
Load the snapshots and update their project name and project ID to be the same as the main project.
|
||||
Regenerate all the node, link and drawing IDs
|
||||
"""
|
||||
|
||||
for snapshot in os.listdir(snapshots_path):
|
||||
if not snapshot.endswith(".gns3project"):
|
||||
for snapshot in os.listdir(snapshots_dir):
|
||||
if not (snapshot.endswith(".gns3snapshot") or snapshot.endswith(".gns3project")):
|
||||
continue
|
||||
snapshot_path = os.path.join(snapshots_path, snapshot)
|
||||
with tempfile.TemporaryDirectory(dir=snapshots_path) as tmpdir:
|
||||
snapshot_path = os.path.join(snapshots_dir, snapshot)
|
||||
with tempfile.TemporaryDirectory(dir=snapshots_dir) as tmpdir:
|
||||
|
||||
# extract everything to a temporary directory
|
||||
try:
|
||||
@@ -288,9 +314,9 @@ async def _import_snapshots(snapshots_path, project_name, project_id):
|
||||
topology_file_path = os.path.join(tmpdir, "project.gns3")
|
||||
with open(topology_file_path, encoding="utf-8") as f:
|
||||
topology = json.load(f)
|
||||
|
||||
topology["name"] = project_name
|
||||
topology["project_id"] = project_id
|
||||
regenerate_topology_ids(topology, project_path, reset_mac_addresses)
|
||||
with open(topology_file_path, "w+", encoding="utf-8") as f:
|
||||
json.dump(topology, f, indent=4, sort_keys=True)
|
||||
except OSError as e:
|
||||
@@ -308,5 +334,6 @@ async def _import_snapshots(snapshots_path, project_name, project_id):
|
||||
async with aiofiles.open(snapshot_path, 'wb+') as f:
|
||||
async for chunk in zstream:
|
||||
await f.write(chunk)
|
||||
log.info("Project '{}': updated and repacked snapshot file '{}'".format(project_name, snapshot))
|
||||
except OSError as e:
|
||||
raise aiohttp.web.HTTPConflict(text="Cannot update snapshot '{}': the snapshot cannot be recreated: {}".format(os.path.basename(snapshot), e))
|
||||
@@ -91,7 +91,7 @@ class Node:
|
||||
self._first_port_name = None
|
||||
self._console_auto_start = False
|
||||
|
||||
# This properties will be recompute
|
||||
# This properties will be recomputed
|
||||
ignore_properties = ("width", "height", "hover_symbol")
|
||||
self.properties = kwargs.pop('properties', {})
|
||||
|
||||
@@ -382,6 +382,7 @@ class Node:
|
||||
await self.parse_node_response(response.json)
|
||||
return True
|
||||
trial += 1
|
||||
return False
|
||||
|
||||
async def update(self, **kwargs):
|
||||
"""
|
||||
|
||||
@@ -84,9 +84,9 @@ class Port:
|
||||
# If port name format has changed we use the port name as the short name (1.X behavior)
|
||||
if self._short_name:
|
||||
return self._short_name
|
||||
elif '/' in self._name:
|
||||
elif self._name and '/' in self._name:
|
||||
return self._name.replace(self.long_name_type(), self.short_name_type())
|
||||
elif self._name.startswith("{}{}".format(self.long_name_type(), self._interface_number)):
|
||||
elif self._name and self._name.startswith("{}{}".format(self.long_name_type(), self._interface_number)):
|
||||
return self.short_name_type() + "{}".format(self._interface_number)
|
||||
return self._name
|
||||
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import sys
|
||||
import re
|
||||
import os
|
||||
import json
|
||||
@@ -46,7 +45,7 @@ from ..utils.asyncio import locking
|
||||
from ..utils.asyncio import aiozipstream
|
||||
from ..utils.asyncio import wait_run_in_executor
|
||||
from .export_project import export_project
|
||||
from .import_project import import_project, _move_node_file
|
||||
from .import_project import import_project, update_snapshots, regenerate_topology_ids
|
||||
|
||||
import logging
|
||||
log = logging.getLogger(__name__)
|
||||
@@ -96,6 +95,7 @@ class Project:
|
||||
self._show_interface_labels = show_interface_labels
|
||||
self._variables = variables
|
||||
self._supplier = supplier
|
||||
self._snapshots_config_file = "snapshots.conf"
|
||||
|
||||
self._loading = False
|
||||
self._closing = False
|
||||
@@ -189,19 +189,7 @@ class Project:
|
||||
self._drawings = {}
|
||||
self._snapshots = {}
|
||||
self._computes = []
|
||||
|
||||
# List the available snapshots
|
||||
snapshot_dir = os.path.join(self.path, "snapshots")
|
||||
if os.path.exists(snapshot_dir):
|
||||
for snap in os.listdir(snapshot_dir):
|
||||
if snap.endswith(".gns3project"):
|
||||
try:
|
||||
snapshot = Snapshot(self, filename=snap)
|
||||
except ValueError:
|
||||
log.error("Invalid snapshot file: {}".format(snap))
|
||||
continue
|
||||
self._snapshots[snapshot.id] = snapshot
|
||||
|
||||
self._load_snapshot_config()
|
||||
# Create the project on demand on the compute node
|
||||
self._project_created_on_compute = set()
|
||||
|
||||
@@ -782,6 +770,59 @@ class Project:
|
||||
except KeyError:
|
||||
raise aiohttp.web.HTTPNotFound(text="Snapshot ID {} doesn't exist".format(snapshot_id))
|
||||
|
||||
def _load_snapshot_config(self):
|
||||
|
||||
snapshot_dir = os.path.join(self.path, "snapshots")
|
||||
self._snapshot_conf_path = os.path.join(snapshot_dir, self._snapshots_config_file)
|
||||
self._snapshot_conf = []
|
||||
if os.path.isfile(self._snapshot_conf_path):
|
||||
try:
|
||||
with open(self._snapshot_conf_path, encoding="utf-8") as f:
|
||||
self._snapshot_conf = json.load(f)
|
||||
except (OSError, UnicodeDecodeError, ValueError) as e:
|
||||
raise aiohttp.web.HTTPConflict(text="Could not read snapshot config {}: {}".format(self._snapshot_conf_path, str(e)))
|
||||
|
||||
# Load all legacy snapshots (.gns3project files) to create an initial snapshot config if it doesn't exist
|
||||
if os.path.exists(snapshot_dir) and not self._snapshot_conf:
|
||||
for snap in os.listdir(snapshot_dir):
|
||||
if snap.endswith(".gns3project"):
|
||||
try:
|
||||
snapshot = Snapshot(self, filename=snap)
|
||||
except ValueError:
|
||||
log.error("Invalid snapshot file: {}".format(snap))
|
||||
continue
|
||||
self._snapshots[snapshot.id] = snapshot
|
||||
else:
|
||||
# Create the Snapshot instances from the snapshot config file
|
||||
for snapshot_entry in self._snapshot_conf:
|
||||
try:
|
||||
path = os.path.join(snapshot_dir, snapshot_entry["filename"])
|
||||
if not os.path.isfile(path):
|
||||
log.warning("Snapshot file '{}' does not exist".format(path))
|
||||
continue
|
||||
snapshot_entry.pop("project_id")
|
||||
snapshot = Snapshot(self, **snapshot_entry)
|
||||
self._snapshots[snapshot.id] = snapshot
|
||||
except KeyError:
|
||||
log.error("Invalid entry in snapshot config file: {}".format(snapshot_entry))
|
||||
continue
|
||||
|
||||
self._save_snapshot_config()
|
||||
|
||||
def _save_snapshot_config(self):
|
||||
|
||||
if not self._snapshots:
|
||||
return
|
||||
|
||||
self._snapshot_conf = []
|
||||
for snapshot in self._snapshots.values():
|
||||
self._snapshot_conf.append(snapshot.__json__())
|
||||
try:
|
||||
with open(self._snapshot_conf_path, 'w+') as f:
|
||||
json.dump(self._snapshot_conf, f, indent=4)
|
||||
except OSError as e:
|
||||
log.error("Cannot write snapshot config '{}': {}".format(self._snapshot_conf_path, e))
|
||||
|
||||
@open_required
|
||||
async def snapshot(self, name):
|
||||
"""
|
||||
@@ -795,12 +836,14 @@ class Project:
|
||||
snapshot = Snapshot(self, name=name)
|
||||
await snapshot.create()
|
||||
self._snapshots[snapshot.id] = snapshot
|
||||
self._save_snapshot_config()
|
||||
return snapshot
|
||||
|
||||
@open_required
|
||||
async def delete_snapshot(self, snapshot_id):
|
||||
snapshot = self.get_snapshot(snapshot_id)
|
||||
del self._snapshots[snapshot.id]
|
||||
self._save_snapshot_config()
|
||||
os.remove(snapshot.path)
|
||||
|
||||
@locking
|
||||
@@ -891,7 +934,7 @@ class Project:
|
||||
def _get_default_project_directory(cls):
|
||||
"""
|
||||
Return the default location for the project directory
|
||||
depending of the operating system
|
||||
depending on the operating system
|
||||
"""
|
||||
|
||||
server_config = Config.instance().get_section_config("Server")
|
||||
@@ -912,7 +955,7 @@ class Project:
|
||||
Load topology elements
|
||||
"""
|
||||
|
||||
if self._closing is True:
|
||||
if self._closing:
|
||||
raise aiohttp.web.HTTPConflict(text="Project is closing, please try again in a few seconds...")
|
||||
|
||||
if self._status == "opened":
|
||||
@@ -1083,7 +1126,14 @@ class Project:
|
||||
with tempfile.TemporaryDirectory(dir=working_dir) as tmpdir:
|
||||
# Do not compress the exported project when duplicating
|
||||
with aiozipstream.ZipFile(compression=zipfile.ZIP_STORED) as zstream:
|
||||
await export_project(zstream, self, tmpdir, keep_compute_ids=True, allow_all_nodes=True, reset_mac_addresses=reset_mac_addresses)
|
||||
await export_project(
|
||||
zstream,
|
||||
self,
|
||||
tmpdir,
|
||||
keep_compute_ids=True,
|
||||
include_snapshots=True,
|
||||
allow_all_nodes=True
|
||||
)
|
||||
|
||||
# export the project to a temporary location
|
||||
project_path = os.path.join(tmpdir, "project.gns3p")
|
||||
@@ -1092,11 +1142,20 @@ class Project:
|
||||
async for chunk in zstream:
|
||||
await f.write(chunk)
|
||||
|
||||
# import the temporary project
|
||||
new_project_id = str(uuid.uuid4())
|
||||
# import the duplicated project
|
||||
with open(project_path, "rb") as f:
|
||||
project = await import_project(self._controller, str(uuid.uuid4()), f, location=location, name=name, keep_compute_ids=True)
|
||||
project = await import_project(
|
||||
self._controller,
|
||||
new_project_id,
|
||||
f,
|
||||
location=location,
|
||||
name=name,
|
||||
reset_mac_addresses=reset_mac_addresses,
|
||||
keep_compute_ids=True
|
||||
)
|
||||
|
||||
log.info("Project '{}' duplicated in {:.4f} seconds".format(project.name, time.time() - begin))
|
||||
log.info("Project '{}': duplicated in {:.4f} seconds".format(project.name, time.time() - begin))
|
||||
except (ValueError, OSError, UnicodeEncodeError) as e:
|
||||
raise aiohttp.web.HTTPConflict(text="Cannot duplicate project: {}".format(str(e)))
|
||||
|
||||
@@ -1105,6 +1164,62 @@ class Project:
|
||||
|
||||
return project
|
||||
|
||||
async def _fast_duplication(self, name=None, location=None, reset_mac_addresses=True):
|
||||
"""
|
||||
Fast duplication of a project.
|
||||
|
||||
Copy the project files directly rather than in an import-export fashion.
|
||||
|
||||
:param name: Name of the new project. A new one will be generated in case of conflicts
|
||||
:param location: Parent directory of the new project
|
||||
:param reset_mac_addresses: Reset MAC addresses for the duplicated project
|
||||
"""
|
||||
|
||||
# remote replication is not supported with remote computes
|
||||
for compute in self.computes:
|
||||
if compute.id != "local":
|
||||
log.warning("Fast duplication is not supported with remote compute: '{}'".format(compute.id))
|
||||
return None
|
||||
# work dir
|
||||
p_work = pathlib.Path(location or self.path).parent.absolute()
|
||||
t0 = time.time()
|
||||
new_project_id = str(uuid.uuid4())
|
||||
if location:
|
||||
new_project_path = p_work.joinpath(location)
|
||||
else:
|
||||
new_project_path = p_work.joinpath(new_project_id)
|
||||
# copy dir
|
||||
await wait_run_in_executor(shutil.copytree, self.path, new_project_path.as_posix(), symlinks=True, ignore_dangling_symlinks=True)
|
||||
log.info("Project content copied from '{}' to '{}' in {}s".format(self.path, new_project_path, time.time() - t0))
|
||||
topology = json.loads(new_project_path.joinpath('{}.gns3'.format(self.name)).read_bytes())
|
||||
project_name = name or topology["name"]
|
||||
# If the project name is already used we generate a new one
|
||||
project_name = self.controller.get_free_project_name(project_name)
|
||||
topology["name"] = project_name
|
||||
# To avoid unexpected behavior (project start without manual operations just after import)
|
||||
topology["auto_start"] = False
|
||||
topology["auto_open"] = False
|
||||
topology["auto_close"] = False
|
||||
|
||||
# regenerate IDs for the duplicated project
|
||||
regenerate_topology_ids(topology, new_project_path, reset_mac_addresses)
|
||||
|
||||
# dump the updated .gns3 project file
|
||||
dot_gns3_path = new_project_path.joinpath('{}.gns3'.format(project_name))
|
||||
topology["project_id"] = new_project_id
|
||||
with open(dot_gns3_path, "w+") as f:
|
||||
json.dump(topology, f, indent=4, sort_keys=True)
|
||||
|
||||
# update the snapshots with new IDs
|
||||
snapshots_dir = os.path.join(new_project_path, "snapshots")
|
||||
if os.path.isdir(snapshots_dir):
|
||||
await update_snapshots(snapshots_dir, new_project_path, project_name, new_project_id)
|
||||
|
||||
os.remove(new_project_path.joinpath('{}.gns3'.format(self.name)))
|
||||
project = await self.controller.load_project(dot_gns3_path, load=False)
|
||||
log.info("Project '{}': fast duplicated in {:.4f} seconds".format(project.name, time.time() - t0))
|
||||
return project
|
||||
|
||||
def is_running(self):
|
||||
"""
|
||||
If a node is started or paused return True
|
||||
@@ -1203,11 +1318,13 @@ class Project:
|
||||
data['z'] = z
|
||||
data['locked'] = False # duplicated node must not be locked
|
||||
new_node_uuid = str(uuid.uuid4())
|
||||
new_node = await self.add_node(node.compute,
|
||||
node.name,
|
||||
new_node_uuid,
|
||||
node_type=node_type,
|
||||
**data)
|
||||
new_node = await self.add_node(
|
||||
node.compute,
|
||||
node.name,
|
||||
new_node_uuid,
|
||||
node_type=node_type,
|
||||
**data
|
||||
)
|
||||
try:
|
||||
await node.post("/duplicate", timeout=None, data={
|
||||
"destination_node_id": new_node_uuid
|
||||
@@ -1255,72 +1372,4 @@ class Project:
|
||||
def __repr__(self):
|
||||
return "<gns3server.controller.Project {} {}>".format(self._name, self._id)
|
||||
|
||||
async def _fast_duplication(self, name=None, location=None, reset_mac_addresses=True):
|
||||
"""
|
||||
Fast duplication of a project.
|
||||
|
||||
Copy the project files directly rather than in an import-export fashion.
|
||||
|
||||
:param name: Name of the new project. A new one will be generated in case of conflicts
|
||||
:param location: Parent directory of the new project
|
||||
:param reset_mac_addresses: Reset MAC addresses for the new project
|
||||
"""
|
||||
|
||||
# remote replication is not supported with remote computes
|
||||
for compute in self.computes:
|
||||
if compute.id != "local":
|
||||
log.warning("Fast duplication is not supported with remote compute: '{}'".format(compute.id))
|
||||
return None
|
||||
# work dir
|
||||
p_work = pathlib.Path(location or self.path).parent.absolute()
|
||||
t0 = time.time()
|
||||
new_project_id = str(uuid.uuid4())
|
||||
if location:
|
||||
new_project_path = p_work.joinpath(location)
|
||||
else:
|
||||
new_project_path = p_work.joinpath(new_project_id)
|
||||
# copy dir
|
||||
await wait_run_in_executor(shutil.copytree, self.path, new_project_path.as_posix(), symlinks=True, ignore_dangling_symlinks=True)
|
||||
log.info("Project content copied from '{}' to '{}' in {}s".format(self.path, new_project_path, time.time() - t0))
|
||||
topology = json.loads(new_project_path.joinpath('{}.gns3'.format(self.name)).read_bytes())
|
||||
project_name = name or topology["name"]
|
||||
# If the project name is already used we generate a new one
|
||||
project_name = self.controller.get_free_project_name(project_name)
|
||||
topology["name"] = project_name
|
||||
# To avoid unexpected behavior (project start without manual operations just after import)
|
||||
topology["auto_start"] = False
|
||||
topology["auto_open"] = False
|
||||
topology["auto_close"] = False
|
||||
# change node ID
|
||||
node_old_to_new = {}
|
||||
for node in topology["topology"]["nodes"]:
|
||||
new_node_id = str(uuid.uuid4())
|
||||
if "node_id" in node:
|
||||
node_old_to_new[node["node_id"]] = new_node_id
|
||||
_move_node_file(new_project_path, node["node_id"], new_node_id)
|
||||
node["node_id"] = new_node_id
|
||||
if reset_mac_addresses:
|
||||
if "properties" in node:
|
||||
for prop, value in node["properties"].items():
|
||||
# reset the MAC address
|
||||
if prop in ("mac_addr", "mac_address"):
|
||||
node["properties"][prop] = None
|
||||
# change link ID
|
||||
for link in topology["topology"]["links"]:
|
||||
link["link_id"] = str(uuid.uuid4())
|
||||
for node in link["nodes"]:
|
||||
node["node_id"] = node_old_to_new[node["node_id"]]
|
||||
# Generate new drawings id
|
||||
for drawing in topology["topology"]["drawings"]:
|
||||
drawing["drawing_id"] = str(uuid.uuid4())
|
||||
|
||||
# And we dump the updated.gns3
|
||||
dot_gns3_path = new_project_path.joinpath('{}.gns3'.format(project_name))
|
||||
topology["project_id"] = new_project_id
|
||||
with open(dot_gns3_path, "w+") as f:
|
||||
json.dump(topology, f, indent=4)
|
||||
|
||||
os.remove(new_project_path.joinpath('{}.gns3'.format(self.name)))
|
||||
project = await self.controller.load_project(dot_gns3_path, load=False)
|
||||
log.info("Project '{}' fast duplicated in {:.4f} seconds".format(project.name, time.time() - t0))
|
||||
return project
|
||||
@@ -35,30 +35,47 @@ import logging
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
# The string use to extract the date from the filename
|
||||
FILENAME_TIME_FORMAT = "%d%m%y_%H%M%S"
|
||||
# Used to extract the date and time from the filename
|
||||
FILENAME_DATETIME_FORMAT = "%d%m%y_%H%M%S"
|
||||
|
||||
# Used to create a description of the snapshot with a human-readable date and time
|
||||
DESCRIPTION_DATETIME_FORMAT = "%Y-%m-%d at %H:%M:%S"
|
||||
|
||||
class Snapshot:
|
||||
"""
|
||||
A snapshot object
|
||||
"""
|
||||
|
||||
def __init__(self, project, name=None, filename=None):
|
||||
def __init__(self, project, snapshot_id=None, name=None, filename=None, created_at=None, description=None):
|
||||
|
||||
assert filename or name, "You need to pass a name or a filename"
|
||||
|
||||
self._id = str(uuid.uuid4()) # We don't need to keep id between project loading because they are use only as key for operation like delete, update.. but have no impact on disk
|
||||
if snapshot_id:
|
||||
self._id = snapshot_id
|
||||
else:
|
||||
self._id = str(uuid.uuid4())
|
||||
|
||||
self._project = project
|
||||
if name:
|
||||
self._name = name
|
||||
self._created_at = datetime.now(timezone.utc).timestamp()
|
||||
filename = self._name + "_" + datetime.fromtimestamp(self._created_at, tz=timezone.utc).replace(tzinfo=None).strftime(FILENAME_TIME_FORMAT) + ".gns3project"
|
||||
|
||||
if created_at:
|
||||
self._created_at = created_at
|
||||
else:
|
||||
self._created_at = int(datetime.now(timezone.utc).timestamp())
|
||||
if not filename:
|
||||
filename = self._name + ".gns3snapshot"
|
||||
else:
|
||||
self._name = filename.rsplit("_", 2)[0]
|
||||
datestring = filename.replace(self._name + "_", "").split(".")[0]
|
||||
self._created_at = datetime.strptime(datestring, FILENAME_TIME_FORMAT).replace(tzinfo=timezone.utc).timestamp()
|
||||
self._created_at = int(datetime.strptime(datestring, FILENAME_DATETIME_FORMAT).replace(tzinfo=timezone.utc).timestamp())
|
||||
|
||||
if not description:
|
||||
date = datetime.fromtimestamp(self._created_at, tz=timezone.utc).replace(tzinfo=None).strftime(DESCRIPTION_DATETIME_FORMAT)
|
||||
description = "Snapshot '{}' taken on {}".format(self._name, date)
|
||||
|
||||
self._description = description
|
||||
self._filename = filename
|
||||
self._path = os.path.join(project.path, "snapshots", filename)
|
||||
|
||||
@property
|
||||
@@ -69,13 +86,17 @@ class Snapshot:
|
||||
def name(self):
|
||||
return self._name
|
||||
|
||||
@property
|
||||
def description(self):
|
||||
return self._description
|
||||
|
||||
@property
|
||||
def path(self):
|
||||
return self._path
|
||||
|
||||
@property
|
||||
def created_at(self):
|
||||
return int(self._created_at)
|
||||
return self._created_at
|
||||
|
||||
async def create(self):
|
||||
"""
|
||||
@@ -114,14 +135,22 @@ class Snapshot:
|
||||
await self._project.close(ignore_notification=True)
|
||||
|
||||
try:
|
||||
begin = time.time()
|
||||
# delete the current project files
|
||||
project_files_path = os.path.join(self._project.path, "project-files")
|
||||
if os.path.exists(project_files_path):
|
||||
await wait_run_in_executor(shutil.rmtree, project_files_path)
|
||||
with open(self._path, "rb") as f:
|
||||
project = await import_project(self._project.controller, self._project.id, f, location=self._project.path,
|
||||
auto_start=self._project.auto_start, auto_open=self._project.auto_open,
|
||||
auto_close=self._project.auto_close)
|
||||
project = await import_project(
|
||||
self._project.controller,
|
||||
self._project.id,
|
||||
f,
|
||||
location=self._project.path,
|
||||
auto_start=self._project.auto_start,
|
||||
auto_open=self._project.auto_open,
|
||||
auto_close=self._project.auto_close
|
||||
)
|
||||
log.info("Snapshot '{}' restored in {:.4f} seconds".format(self.name, time.time() - begin))
|
||||
except (OSError, PermissionError) as e:
|
||||
raise aiohttp.web.HTTPConflict(text=str(e))
|
||||
await project.open()
|
||||
@@ -132,6 +161,8 @@ class Snapshot:
|
||||
return {
|
||||
"snapshot_id": self._id,
|
||||
"name": self._name,
|
||||
"created_at": int(self._created_at),
|
||||
"created_at": self._created_at,
|
||||
"description": self._description,
|
||||
"filename": self._filename,
|
||||
"project_id": self._project.id
|
||||
}
|
||||
@@ -57,7 +57,7 @@ class CrashReport:
|
||||
Report crash to a third party service
|
||||
"""
|
||||
|
||||
DSN = "https://5bfcec70239c428d44aafef68f3eea79@o19455.ingest.us.sentry.io/38482"
|
||||
DSN = "https://74851857a3f05aecd909415e2a4cbd60@o19455.ingest.us.sentry.io/38482"
|
||||
_instance = None
|
||||
|
||||
def __init__(self):
|
||||
|
||||
@@ -43,17 +43,17 @@ IOU_TEMPLATE_PROPERTIES = {
|
||||
"ram": {
|
||||
"description": "RAM in MB",
|
||||
"type": "integer",
|
||||
"default": 256
|
||||
"default": 1024
|
||||
},
|
||||
"nvram": {
|
||||
"description": "NVRAM in KB",
|
||||
"type": "integer",
|
||||
"default": 128
|
||||
"default": 256
|
||||
},
|
||||
"use_default_iou_values": {
|
||||
"description": "Use default IOU values",
|
||||
"type": "boolean",
|
||||
"default": True
|
||||
"default": False
|
||||
},
|
||||
"startup_config": {
|
||||
"description": "Startup-config of IOU",
|
||||
|
||||
@@ -25,6 +25,10 @@ SNAPSHOT_CREATE_SCHEMA = {
|
||||
"description": "Snapshot name",
|
||||
"minLength": 1
|
||||
},
|
||||
"description": {
|
||||
"description": "Snapshot description",
|
||||
"minLength": 1
|
||||
},
|
||||
},
|
||||
"additionalProperties": False,
|
||||
"required": ["name"]
|
||||
@@ -50,7 +54,17 @@ SNAPSHOT_OBJECT_SCHEMA = {
|
||||
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$"
|
||||
},
|
||||
"name": {
|
||||
"description": "Project name",
|
||||
"description": "Snapshot name",
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"filename": {
|
||||
"description": "Snapshot filename",
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"description": {
|
||||
"description": "Snapshot description",
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
@@ -60,5 +74,5 @@ SNAPSHOT_OBJECT_SCHEMA = {
|
||||
}
|
||||
},
|
||||
"additionalProperties": False,
|
||||
"required": ["snapshot_id", "name", "created_at", "project_id"]
|
||||
"required": ["snapshot_id", "name", "filename", "created_at", "description", "project_id"]
|
||||
}
|
||||
+1
-1
@@ -1 +1 @@
|
||||
"use strict";(self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[]).push([[26],{91026:function(W,g,a){a.r(g),a.d(g,{TopologySummaryComponent:function(){return U}});var t=a(38999),_=a(96852),h=a(14200),f=a(36889),v=a(3941),y=a(15132),p=a(40098),x=a(39095),c=a(88802),S=a(73044),d=a(59412),T=a(93386);function C(i,e){if(1&i){var o=t.EpF();t.TgZ(0,"div",2),t.NdJ("mousemove",function(r){return t.CHM(o),t.oxw().dragWidget(r)},!1,t.evT)("mouseup",function(){return t.CHM(o),t.oxw().toggleDragging(!1)},!1,t.evT),t.qZA()}}function b(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",29),t.qZA())}function E(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",30),t.qZA())}function Z(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",31),t.qZA())}function O(i,e){if(1&i&&(t.TgZ(0,"div"),t._uU(1),t.qZA()),2&i){var o=t.oxw().$implicit;t.xp6(1),t.lnq(" ",o.console_type,"://",o.console_host,":",o.console," ")}}function P(i,e){1&i&&(t.TgZ(0,"div"),t._uU(1," none "),t.qZA())}function M(i,e){if(1&i&&(t.TgZ(0,"div",25),t.TgZ(1,"div"),t.YNc(2,b,2,0,"svg",26),t.YNc(3,E,2,0,"svg",26),t.YNc(4,Z,2,0,"svg",26),t._uU(5),t.qZA(),t.YNc(6,O,2,3,"div",27),t.YNc(7,P,2,0,"div",27),t.qZA()),2&i){var o=e.$implicit;t.xp6(2),t.Q6J("ngIf","started"===o.status),t.xp6(1),t.Q6J("ngIf","suspended"===o.status),t.xp6(1),t.Q6J("ngIf","stopped"===o.status),t.xp6(1),t.hij(" ",o.name," "),t.xp6(1),t.Q6J("ngIf",null!=o.console&&null!=o.console&&"none"!=o.console_type),t.xp6(1),t.Q6J("ngIf",null==o.console||"none"===o.console_type)}}function w(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",29),t.qZA())}function A(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",31),t.qZA())}function F(i,e){if(1&i&&(t.TgZ(0,"div",25),t.TgZ(1,"div"),t.YNc(2,w,2,0,"svg",26),t.YNc(3,A,2,0,"svg",26),t._uU(4),t.qZA(),t.TgZ(5,"div"),t._uU(6),t.qZA(),t.TgZ(7,"div"),t._uU(8),t.qZA(),t.qZA()),2&i){var o=e.$implicit,s=t.oxw(2);t.xp6(2),t.Q6J("ngIf",o.connected),t.xp6(1),t.Q6J("ngIf",!o.connected),t.xp6(1),t.hij(" ",o.name," "),t.xp6(2),t.hij(" ",o.host," "),t.xp6(2),t.hij(" ",s.server.location," ")}}var I=function(i){return{lightTheme:i}},D=function(){return{right:!0,left:!0,bottom:!0,top:!0}};function N(i,e){if(1&i){var o=t.EpF();t.TgZ(0,"div",3),t.NdJ("mousedown",function(){return t.CHM(o),t.oxw().toggleDragging(!0)})("resizeStart",function(){return t.CHM(o),t.oxw().toggleDragging(!1)})("resizeEnd",function(n){return t.CHM(o),t.oxw().onResizeEnd(n)}),t.TgZ(1,"div",4),t.TgZ(2,"mat-tab-group"),t.TgZ(3,"mat-tab",5),t.NdJ("click",function(){return t.CHM(o),t.oxw().toggleTopologyVisibility(!0)}),t.TgZ(4,"div",6),t.TgZ(5,"div",7),t.TgZ(6,"mat-select",8),t.TgZ(7,"mat-optgroup",9),t.TgZ(8,"mat-option",10),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("started")}),t._uU(9,"started"),t.qZA(),t.TgZ(10,"mat-option",11),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("suspended")}),t._uU(11,"suspended"),t.qZA(),t.TgZ(12,"mat-option",12),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("stopped")}),t._uU(13,"stopped"),t.qZA(),t.qZA(),t.TgZ(14,"mat-optgroup",13),t.TgZ(15,"mat-option",14),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyCaptureFilter("capture")}),t._uU(16,"active capture(s)"),t.qZA(),t.TgZ(17,"mat-option",15),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyCaptureFilter("packet")}),t._uU(18,"active packet captures"),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.TgZ(19,"div",16),t.TgZ(20,"mat-select",17),t.NdJ("selectionChange",function(){return t.CHM(o),t.oxw().setSortingOrder()})("valueChange",function(n){return t.CHM(o),t.oxw().sortingOrder=n}),t.TgZ(21,"mat-option",18),t._uU(22,"sort by name ascending"),t.qZA(),t.TgZ(23,"mat-option",19),t._uU(24,"sort by name descending"),t.qZA(),t.qZA(),t.qZA(),t._UZ(25,"mat-divider",20),t.TgZ(26,"div",21),t.YNc(27,M,8,6,"div",22),t.qZA(),t.qZA(),t.qZA(),t.TgZ(28,"mat-tab",23),t.NdJ("click",function(){return t.CHM(o),t.oxw().toggleTopologyVisibility(!1)}),t.TgZ(29,"div",6),t.TgZ(30,"div",24),t.YNc(31,F,9,5,"div",22),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.qZA()}if(2&i){var s=t.oxw();t.Q6J("ngStyle",s.style)("ngClass",t.VKq(9,I,s.isLightThemeEnabled))("validateResize",s.validate)("resizeEdges",t.DdM(11,D))("enableGhostResize",!0),t.xp6(20),t.Q6J("value",s.sortingOrder),t.xp6(6),t.Q6J("ngStyle",s.styleInside),t.xp6(1),t.Q6J("ngForOf",s.filteredNodes),t.xp6(4),t.Q6J("ngForOf",s.computes)}}var U=function(){function i(e,o,s,r,n){this.nodesDataSource=e,this.projectService=o,this.computeService=s,this.linksDataSource=r,this.themeService=n,this.closeTopologySummary=new t.vpe,this.style={},this.styleInside={height:"280px"},this.subscriptions=[],this.nodes=[],this.filteredNodes=[],this.sortingOrder="asc",this.startedStatusFilterEnabled=!1,this.suspendedStatusFilterEnabled=!1,this.stoppedStatusFilterEnabled=!1,this.captureFilterEnabled=!1,this.packetFilterEnabled=!1,this.computes=[],this.isTopologyVisible=!0,this.isDraggLine truncated
|
||||
"use strict";(self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[]).push([[26],{91026:function(W,g,a){a.r(g),a.d(g,{TopologySummaryComponent:function(){return U}});var t=a(38999),_=a(96852),h=a(14200),f=a(36889),v=a(3941),y=a(15132),p=a(40098),x=a(39095),c=a(88802),S=a(73044),d=a(59412),T=a(93386);function C(i,e){if(1&i){var o=t.EpF();t.TgZ(0,"div",2),t.NdJ("mousemove",function(r){return t.CHM(o),t.oxw().dragWidget(r)},!1,t.evT)("mouseup",function(){return t.CHM(o),t.oxw().toggleDragging(!1)},!1,t.evT),t.qZA()}}function b(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",29),t.qZA())}function E(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",30),t.qZA())}function Z(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",31),t.qZA())}function O(i,e){if(1&i&&(t.TgZ(0,"div"),t._uU(1),t.qZA()),2&i){var o=t.oxw().$implicit;t.xp6(1),t.lnq(" ",o.console_type,"://",o.console_host,":",o.console," ")}}function P(i,e){1&i&&(t.TgZ(0,"div"),t._uU(1," none "),t.qZA())}function M(i,e){if(1&i&&(t.TgZ(0,"div",25),t.TgZ(1,"div"),t.YNc(2,b,2,0,"svg",26),t.YNc(3,E,2,0,"svg",26),t.YNc(4,Z,2,0,"svg",26),t._uU(5),t.qZA(),t.YNc(6,O,2,3,"div",27),t.YNc(7,P,2,0,"div",27),t.qZA()),2&i){var o=e.$implicit;t.xp6(2),t.Q6J("ngIf","started"===o.status),t.xp6(1),t.Q6J("ngIf","suspended"===o.status),t.xp6(1),t.Q6J("ngIf","stopped"===o.status),t.xp6(1),t.hij(" ",o.name," "),t.xp6(1),t.Q6J("ngIf",null!=o.console&&null!=o.console&&"none"!=o.console_type),t.xp6(1),t.Q6J("ngIf",null==o.console||"none"===o.console_type)}}function w(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",29),t.qZA())}function A(i,e){1&i&&(t.O4$(),t.TgZ(0,"svg",28),t._UZ(1,"rect",31),t.qZA())}function F(i,e){if(1&i&&(t.TgZ(0,"div",25),t.TgZ(1,"div"),t.YNc(2,w,2,0,"svg",26),t.YNc(3,A,2,0,"svg",26),t._uU(4),t.qZA(),t.TgZ(5,"div"),t._uU(6),t.qZA(),t.TgZ(7,"div"),t._uU(8),t.qZA(),t.qZA()),2&i){var o=e.$implicit,s=t.oxw(2);t.xp6(2),t.Q6J("ngIf",o.connected),t.xp6(1),t.Q6J("ngIf",!o.connected),t.xp6(1),t.hij(" ",o.name," "),t.xp6(2),t.hij(" ",o.host," "),t.xp6(2),t.hij(" ",s.server.location," ")}}var I=function(i){return{lightTheme:i}},D=function(){return{right:!0,left:!0,bottom:!0,top:!0}};function N(i,e){if(1&i){var o=t.EpF();t.TgZ(0,"div",3),t.NdJ("mousedown",function(){return t.CHM(o),t.oxw().toggleDragging(!0)})("resizeStart",function(){return t.CHM(o),t.oxw().toggleDragging(!1)})("resizeEnd",function(n){return t.CHM(o),t.oxw().onResizeEnd(n)}),t.TgZ(1,"div",4),t.TgZ(2,"mat-tab-group"),t.TgZ(3,"mat-tab",5),t.NdJ("click",function(){return t.CHM(o),t.oxw().toggleTopologyVisibility(!0)}),t.TgZ(4,"div",6),t.TgZ(5,"div",7),t.TgZ(6,"mat-select",8),t.TgZ(7,"mat-optgroup",9),t.TgZ(8,"mat-option",10),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("started")}),t._uU(9,"started"),t.qZA(),t.TgZ(10,"mat-option",11),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("suspended")}),t._uU(11,"suspended"),t.qZA(),t.TgZ(12,"mat-option",12),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyStatusFilter("stopped")}),t._uU(13,"stopped"),t.qZA(),t.qZA(),t.TgZ(14,"mat-optgroup",13),t.TgZ(15,"mat-option",14),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyCaptureFilter("capture")}),t._uU(16,"active capture(s)"),t.qZA(),t.TgZ(17,"mat-option",15),t.NdJ("onSelectionChange",function(){return t.CHM(o),t.oxw().applyCaptureFilter("packet")}),t._uU(18,"active packet captures"),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.TgZ(19,"div",16),t.TgZ(20,"mat-select",17),t.NdJ("selectionChange",function(){return t.CHM(o),t.oxw().setSortingOrder()})("valueChange",function(n){return t.CHM(o),t.oxw().sortingOrder=n}),t.TgZ(21,"mat-option",18),t._uU(22,"sort by name ascending"),t.qZA(),t.TgZ(23,"mat-option",19),t._uU(24,"sort by name descending"),t.qZA(),t.qZA(),t.qZA(),t._UZ(25,"mat-divider",20),t.TgZ(26,"div",21),t.YNc(27,M,8,6,"div",22),t.qZA(),t.qZA(),t.qZA(),t.TgZ(28,"mat-tab",23),t.NdJ("click",function(){return t.CHM(o),t.oxw().toggleTopologyVisibility(!1)}),t.TgZ(29,"div",6),t.TgZ(30,"div",24),t.YNc(31,F,9,5,"div",22),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.qZA(),t.qZA()}if(2&i){var s=t.oxw();t.Q6J("ngStyle",s.style)("ngClass",t.VKq(9,I,s.isLightThemeEnabled))("validateResize",s.validate)("resizeEdges",t.DdM(11,D))("enableGhostResize",!0),t.xp6(20),t.Q6J("value",s.sortingOrder),t.xp6(6),t.Q6J("ngStyle",s.styleInside),t.xp6(1),t.Q6J("ngForOf",s.filteredNodes),t.xp6(4),t.Q6J("ngForOf",s.computes)}}var U=function(){function i(e,o,s,r,n){this.nodesDataSource=e,this.projectService=o,this.computeService=s,this.linksDataSource=r,this.themeService=n,this.closeTopologySummary=new t.vpe,this.style={},this.styleInside={height:"280px"},this.subscriptions=[],this.nodes=[],this.filteredNodes=[],this.sortingOrder="asc",this.startedStatusFilterEnabled=!1,this.suspendedStatusFilterEnabled=!1,this.stoppedStatusFilterEnabled=!1,this.captureFilterEnabled=!1,this.packetFilterEnabled=!1,this.computes=[],this.isTopologyVisible=!0,this.isDraggLine truncated
|
||||
@@ -31,7 +31,7 @@
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
<style>@charset "UTF-8";:root{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13,110,253;--bs-secondary-rgb:108,117,125;--bs-success-rgb:25,135,84;--bs-info-rgb:13,202,240;--bs-warning-rgb:255,193,7;--bs-danger-rgb:220,53,69;--bs-light-rgb:248,249,250;--bs-dark-rgb:33,37,41;--bs-white-rgb:255,255,255;--bs-black-rgb:0,0,0;--bs-body-color-rgb:33,37,41;--bs-body-bg-rgb:255,255,255;--bs-font-sans-serif:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--bs-font-monospace:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--bs-gradient:linear-gradient(180deg,hsla(0,0%,100%,.15),hsla(0,0%,100%,0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-bg:#fff}*,:after,:before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--bs-body-font-family);font-size:1rem;font-size:var(--bs-body-font-size);font-weight:400;font-weight:var(--bs-body-font-weight);line-height:1.5;line-height:var(--bs-body-line-height);color:#212529;color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:#fff;background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}@font-face{font-family:Noto Sans;src:url(NotoSans-Regular.f55982ed9f2bc3af6185.eot);src:local("Noto Sans Regular"),local("NotoSans-Regular"),url(NotoSans-Regular.f55982ed9f2bc3af6185.eot?#iefix) format("embedded-opentype"),url(NotoSans-Regular.730e73a4d4556fa0efe8.woff2) format("woff2"),url(NotoSans-Regular.22c53c8686edcaecdf66.woff) format("woff"),url(NotoSans-Regular.e962f548522aa99bb8f9.ttf) format("truetype"),url(NotoSans-Regular.8142e5b2e99a1cccafb7.svg#NotoSans-Regular) format("svg");font-weight:400;font-style:normal}@font-face{font-family:Noto Sans;src:url(NotoSans-Italic.1506cb93f574152bda3d.eot);src:local("Noto Sans Italic"),local("NotoSans-Italic"),url(NotoSans-Italic.1506cb93f574152bda3d.eot?#iefix) format("embedded-opentype"),url(NotoSans-Italic.ca985d172a576d01c77e.woff2) format("woff2"),url(NotoSans-Italic.8a08f0f08e448e4f522e.woff) format("woff"),url(NotoSans-Italic.08690ed789a5532ed7be.ttf) format("truetype"),url(NotoSans-Italic.cecaa17f122ac96a50f8.svg#NotoSans-Italic) format("svg");font-weight:400;font-style:italic}@font-face{font-family:Noto Sans;src:url(NotoSans-Bold.fe2c3263802c4469728b.eot);src:local("Noto Sans Bold"),local("NotoSans-Bold"),url(NotoSans-Bold.fe2c3263802c4469728b.eot?#iefix) format("embedded-opentype"),url(NotoSans-Bold.3ea2282022a16bb2827b.woff2) format("woff2"),url(NotoSans-Bold.364158e7b3016f83790a.woff) format("woff"),url(NotoSans-Bold.82b1a58ddf26951345dc.ttf) format("truetype"),url(NotoSans-Bold.18ef6a21171328dc11a9.svg#NotoSans-Bold) format("svg");font-weight:700;font-style:normal}@font-face{font-family:Noto Sans;src:url(NotoSans-BoldItalic.b40d78b2f9e2490108d0.eot);src:local("Noto Sans BoldItalic"),local("NotoSans-BoldItalic"),url(NotoSans-BoldItalic.b40d78b2f9e2490108d0.eot?#iefix) format("embedded-opentype"),url(NotoSans-BoldItalic.f2639d17cfb5c6e74edd.woff2) format("woff2"),url(NotoSans-BoldItalic.ed8d2295c0b2e0a854d8.woff) format("woff"),url(NotoSans-BoldItalic.9e49c91c40231a024afb.ttf) format("truetype"),url(NotoSans-BoldItalic.7930d6e32b12448fc0ae.svg#NotoSans-BoldItalic) format("svg");font-weight:700;font-style:italic}body{background-color:#e8ecef}app-root{width:100%}@font-face{font-family:Roboto;font-style:normal;font-display:swap;font-weight:100;src:local("Roboto Thin "),local("Roboto-Thin"),url(roboto-latin-100.c2aa4ab115bf9c6057cb.woff2) format("woff2"),url(roboto-latin-100.a45108d3b34af91f9113.woff) format("woff")}@font-face{font-family:Roboto;font-style:italic;font-display:swap;font-weight:100;src:local("Roboto Thin italic"),local("Roboto-Thinitalic"),url(roboto-latin-100italic.7f839a8652da29745ce4.woff2) format("woff2"),url(roboto-latin-100italic.451d4e559d6f57cdf6a1.woff) format("woff")}@font-face{font-family:Roboto;font-style:normal;font-display:swap;font-weight:300;src:local("RobLine truncated
|
||||
<style>@charset "UTF-8";:root{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13,110,253;--bs-secondary-rgb:108,117,125;--bs-success-rgb:25,135,84;--bs-info-rgb:13,202,240;--bs-warning-rgb:255,193,7;--bs-danger-rgb:220,53,69;--bs-light-rgb:248,249,250;--bs-dark-rgb:33,37,41;--bs-white-rgb:255,255,255;--bs-black-rgb:0,0,0;--bs-body-color-rgb:33,37,41;--bs-body-bg-rgb:255,255,255;--bs-font-sans-serif:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--bs-font-monospace:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--bs-gradient:linear-gradient(180deg,hsla(0,0%,100%,.15),hsla(0,0%,100%,0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-bg:#fff}*,:after,:before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--bs-body-font-family);font-size:1rem;font-size:var(--bs-body-font-size);font-weight:400;font-weight:var(--bs-body-font-weight);line-height:1.5;line-height:var(--bs-body-line-height);color:#212529;color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:#fff;background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}@font-face{font-family:Noto Sans;src:url(NotoSans-Regular.f55982ed9f2bc3af6185.eot);src:local("Noto Sans Regular"),local("NotoSans-Regular"),url(NotoSans-Regular.f55982ed9f2bc3af6185.eot?#iefix) format("embedded-opentype"),url(NotoSans-Regular.730e73a4d4556fa0efe8.woff2) format("woff2"),url(NotoSans-Regular.22c53c8686edcaecdf66.woff) format("woff"),url(NotoSans-Regular.e962f548522aa99bb8f9.ttf) format("truetype"),url(NotoSans-Regular.8142e5b2e99a1cccafb7.svg#NotoSans-Regular) format("svg");font-weight:400;font-style:normal}@font-face{font-family:Noto Sans;src:url(NotoSans-Italic.1506cb93f574152bda3d.eot);src:local("Noto Sans Italic"),local("NotoSans-Italic"),url(NotoSans-Italic.1506cb93f574152bda3d.eot?#iefix) format("embedded-opentype"),url(NotoSans-Italic.ca985d172a576d01c77e.woff2) format("woff2"),url(NotoSans-Italic.8a08f0f08e448e4f522e.woff) format("woff"),url(NotoSans-Italic.08690ed789a5532ed7be.ttf) format("truetype"),url(NotoSans-Italic.cecaa17f122ac96a50f8.svg#NotoSans-Italic) format("svg");font-weight:400;font-style:italic}@font-face{font-family:Noto Sans;src:url(NotoSans-Bold.fe2c3263802c4469728b.eot);src:local("Noto Sans Bold"),local("NotoSans-Bold"),url(NotoSans-Bold.fe2c3263802c4469728b.eot?#iefix) format("embedded-opentype"),url(NotoSans-Bold.3ea2282022a16bb2827b.woff2) format("woff2"),url(NotoSans-Bold.364158e7b3016f83790a.woff) format("woff"),url(NotoSans-Bold.82b1a58ddf26951345dc.ttf) format("truetype"),url(NotoSans-Bold.18ef6a21171328dc11a9.svg#NotoSans-Bold) format("svg");font-weight:700;font-style:normal}@font-face{font-family:Noto Sans;src:url(NotoSans-BoldItalic.b40d78b2f9e2490108d0.eot);src:local("Noto Sans BoldItalic"),local("NotoSans-BoldItalic"),url(NotoSans-BoldItalic.b40d78b2f9e2490108d0.eot?#iefix) format("embedded-opentype"),url(NotoSans-BoldItalic.f2639d17cfb5c6e74edd.woff2) format("woff2"),url(NotoSans-BoldItalic.ed8d2295c0b2e0a854d8.woff) format("woff"),url(NotoSans-BoldItalic.9e49c91c40231a024afb.ttf) format("truetype"),url(NotoSans-BoldItalic.7930d6e32b12448fc0ae.svg#NotoSans-BoldItalic) format("svg");font-weight:700;font-style:italic}body{background-color:#e8ecef}app-root{width:100%}@font-face{font-family:Roboto;font-style:normal;font-display:swap;font-weight:100;src:local("Roboto Thin "),local("Roboto-Thin"),url(roboto-latin-100.c2aa4ab115bf9c6057cb.woff2) format("woff2"),url(roboto-latin-100.a45108d3b34af91f9113.woff) format("woff")}@font-face{font-family:Roboto;font-style:italic;font-display:swap;font-weight:100;src:local("Roboto Thin italic"),local("Roboto-Thinitalic"),url(roboto-latin-100italic.7f839a8652da29745ce4.woff2) format("woff2"),url(roboto-latin-100italic.451d4e559d6f57cdf6a1.woff) format("woff")}@font-face{font-family:Roboto;font-style:normal;font-display:swap;font-weight:300;src:local("RobLine truncated
|
||||
<!-- <body class="mat-app-background" oncontextmenu="return false;"> -->
|
||||
<body class="mat-app-background" oncontextmenu="return false;">
|
||||
<app-root></app-root>
|
||||
@@ -46,6 +46,6 @@
|
||||
|
||||
gtag('config', 'G-0BT7QQV1W1');
|
||||
</script>
|
||||
<script src="runtime.415291667f70565cd8ef.js" defer></script><script src="polyfills-es5.865074f5cd9a121111a2.js" nomodule defer></script><script src="polyfills.2f91a039d848e57ff02e.js" defer></script><script src="main.9bcf455e62558dedfd48.js" defer></script>
|
||||
<script src="runtime.9ddea9674c7a8d625f82.js" defer></script><script src="polyfills-es5.865074f5cd9a121111a2.js" nomodule defer></script><script src="polyfills.2f91a039d848e57ff02e.js" defer></script><script src="main.d74d38241f0602d1b3e0.js" defer></script>
|
||||
|
||||
</body></html>
|
||||
+1
-1
@@ -1 +1 @@
|
||||
(self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[]).push([[179],{98255:function(ue){function q(f){return Promise.resolve().then(function(){var B=new Error("Cannot find module '"+f+"'");throw B.code="MODULE_NOT_FOUND",B})}q.keys=function(){return[]},q.resolve=q,q.id=98255,ue.exports=q},82908:function(ue){ue.exports=function(f,B){(null==B||B>f.length)&&(B=f.length);for(var U=0,V=new Array(B);U<B;U++)V[U]=f[U];return V},ue.exports.default=ue.exports,ue.exports.__esModule=!0},36457:function(ue){ue.exports=function(f){if(Array.isArray(f))return f},ue.exports.default=ue.exports,ue.exports.__esModule=!0},35036:function(ue){ue.exports=function(f,B){var U=null==f?null:"undefined"!=typeof Symbol&&f[Symbol.iterator]||f["@@iterator"];if(null!=U){var N,b,V=[],Z=!0,w=!1;try{for(U=U.call(f);!(Z=(N=U.next()).done)&&(V.push(N.value),!B||V.length!==B);Z=!0);}catch(_){w=!0,b=_}finally{try{!Z&&null!=U.return&&U.return()}finally{if(w)throw b}}return V}},ue.exports.default=ue.exports,ue.exports.__esModule=!0},13969:function(ue){ue.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},ue.exports.default=ue.exports,ue.exports.__esModule=!0},6326:function(ue,q,f){var B=f(36457),U=f(35036),V=f(54850),Z=f(13969);ue.exports=function(N,b){return B(N)||U(N,b)||V(N,b)||Z()},ue.exports.default=ue.exports,ue.exports.__esModule=!0},54850:function(ue,q,f){var B=f(82908);ue.exports=function(V,Z){if(V){if("string"==typeof V)return B(V,Z);var w=Object.prototype.toString.call(V).slice(8,-1);if("Object"===w&&V.constructor&&(w=V.constructor.name),"Map"===w||"Set"===w)return Array.from(V);if("Arguments"===w||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(w))return B(V,Z)}},ue.exports.default=ue.exports,ue.exports.__esModule=!0},26552:function(ue,q,f){ue.exports=f(55590)},61855:function(ue,q,f){"use strict";f.d(q,{ZT:function(){return U},mG:function(){return _},Jh:function(){return I},ev:function(){return R}});var B=function($,ae){return(B=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(se,ce){se.__proto__=ce}||function(se,ce){for(var le in ce)Object.prototype.hasOwnProperty.call(ce,le)&&(se[le]=ce[le])})($,ae)};function U($,ae){if("function"!=typeof ae&&null!==ae)throw new TypeError("Class extends value "+String(ae)+" is not a constructor or null");function se(){this.constructor=$}B($,ae),$.prototype=null===ae?Object.create(ae):(se.prototype=ae.prototype,new se)}function _($,ae,se,ce){return new(se||(se=Promise))(function(oe,Ae){function be(_t){try{qe(ce.next(_t))}catch(yt){Ae(yt)}}function it(_t){try{qe(ce.throw(_t))}catch(yt){Ae(yt)}}function qe(_t){_t.done?oe(_t.value):function(oe){return oe instanceof se?oe:new se(function(Ae){Ae(oe)})}(_t.value).then(be,it)}qe((ce=ce.apply($,ae||[])).next())})}function I($,ae){var ce,le,oe,Ae,se={label:0,sent:function(){if(1&oe[0])throw oe[1];return oe[1]},trys:[],ops:[]};return Ae={next:be(0),throw:be(1),return:be(2)},"function"==typeof Symbol&&(Ae[Symbol.iterator]=function(){return this}),Ae;function be(qe){return function(_t){return function(qe){if(ce)throw new TypeError("Generator is already executing.");for(;se;)try{if(ce=1,le&&(oe=2&qe[0]?le.return:qe[0]?le.throw||((oe=le.return)&&oe.call(le),0):le.next)&&!(oe=oe.call(le,qe[1])).done)return oe;switch(le=0,oe&&(qe=[2&qe[0],oe.value]),qe[0]){case 0:case 1:oe=qe;break;case 4:return se.label++,{value:qe[1],done:!1};case 5:se.label++,le=qe[1],qe=[0];continue;case 7:qe=se.ops.pop(),se.trys.pop();continue;default:if(!(oe=(oe=se.trys).length>0&&oe[oe.length-1])&&(6===qe[0]||2===qe[0])){se=0;continue}if(3===qe[0]&&(!oe||qe[1]>oe[0]&&qe[1]<oe[3])){se.label=qe[1];break}if(6===qe[0]&&se.label<oe[1]){se.label=oe[1],oe=qe;break}if(oe&&se.label<oe[2]){se.label=oe[2],se.ops.push(qe);break}oe[2]&&se.ops.pop(),se.trys.pop();continue}qe=ae.call($,se)}catch(_t){qe=[6,_t],le=0}finally{ce=oe=0}if(5&qe[0])throw qe[1];return{value:qe[0]?qe[1]:void 0,done:!0}}([qe,_t])}}}function R($,ae,se){if(se||2===arguments.length)for(var oe,ce=0,le=ae.length;ce<le;ce++)(oe||!(ce in ae))&&(oe||(oe=Array.prototype.slice.call(ae,0,ce)),oe[ce]=ae[ce]);return $.concat(oe||Array.prototype.slice.call(ae))}},739:function(ue,q,f){"use strict";f.d(q,{l3:function(){return w},_j:function(){return V},LC:function(){return Z},ZN:function(){return O},jt:function(){return b},pV:function(){return T},F4:function(){return S},IO:function(){return k},vP:function(){return I},SB:function(){return A},oB:function(){return D},eR:function(){return v},X$:function(){return N},ZE:function(){return F},k1:function(){return z}});var B=f(14105),U=f(18967),V=function K(){(0,U.Z)(this,K)},Z=function K(){(0,U.Z)(this,K)},w="*";function N(K,j){return{type:7,name:K,definitions:j,options:{}}}function b(K){var j=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:4,styles:j,timings:K}}function I(K){var j=arguments.length>1&&void 0!==arguments[1]?arguments[1]Line truncated
|
||||
(self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[]).push([[179],{98255:function(ue){function q(f){return Promise.resolve().then(function(){var B=new Error("Cannot find module '"+f+"'");throw B.code="MODULE_NOT_FOUND",B})}q.keys=function(){return[]},q.resolve=q,q.id=98255,ue.exports=q},82908:function(ue){ue.exports=function(f,B){(null==B||B>f.length)&&(B=f.length);for(var U=0,V=new Array(B);U<B;U++)V[U]=f[U];return V},ue.exports.default=ue.exports,ue.exports.__esModule=!0},36457:function(ue){ue.exports=function(f){if(Array.isArray(f))return f},ue.exports.default=ue.exports,ue.exports.__esModule=!0},35036:function(ue){ue.exports=function(f,B){var U=null==f?null:"undefined"!=typeof Symbol&&f[Symbol.iterator]||f["@@iterator"];if(null!=U){var N,b,V=[],Z=!0,w=!1;try{for(U=U.call(f);!(Z=(N=U.next()).done)&&(V.push(N.value),!B||V.length!==B);Z=!0);}catch(_){w=!0,b=_}finally{try{!Z&&null!=U.return&&U.return()}finally{if(w)throw b}}return V}},ue.exports.default=ue.exports,ue.exports.__esModule=!0},13969:function(ue){ue.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},ue.exports.default=ue.exports,ue.exports.__esModule=!0},6326:function(ue,q,f){var B=f(36457),U=f(35036),V=f(54850),Z=f(13969);ue.exports=function(N,b){return B(N)||U(N,b)||V(N,b)||Z()},ue.exports.default=ue.exports,ue.exports.__esModule=!0},54850:function(ue,q,f){var B=f(82908);ue.exports=function(V,Z){if(V){if("string"==typeof V)return B(V,Z);var w=Object.prototype.toString.call(V).slice(8,-1);if("Object"===w&&V.constructor&&(w=V.constructor.name),"Map"===w||"Set"===w)return Array.from(V);if("Arguments"===w||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(w))return B(V,Z)}},ue.exports.default=ue.exports,ue.exports.__esModule=!0},26552:function(ue,q,f){ue.exports=f(55590)},61855:function(ue,q,f){"use strict";f.d(q,{ZT:function(){return U},mG:function(){return _},Jh:function(){return I},ev:function(){return R}});var B=function($,ae){return(B=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(se,ce){se.__proto__=ce}||function(se,ce){for(var le in ce)Object.prototype.hasOwnProperty.call(ce,le)&&(se[le]=ce[le])})($,ae)};function U($,ae){if("function"!=typeof ae&&null!==ae)throw new TypeError("Class extends value "+String(ae)+" is not a constructor or null");function se(){this.constructor=$}B($,ae),$.prototype=null===ae?Object.create(ae):(se.prototype=ae.prototype,new se)}function _($,ae,se,ce){return new(se||(se=Promise))(function(oe,Ae){function be(_t){try{qe(ce.next(_t))}catch(yt){Ae(yt)}}function it(_t){try{qe(ce.throw(_t))}catch(yt){Ae(yt)}}function qe(_t){_t.done?oe(_t.value):function(oe){return oe instanceof se?oe:new se(function(Ae){Ae(oe)})}(_t.value).then(be,it)}qe((ce=ce.apply($,ae||[])).next())})}function I($,ae){var ce,le,oe,Ae,se={label:0,sent:function(){if(1&oe[0])throw oe[1];return oe[1]},trys:[],ops:[]};return Ae={next:be(0),throw:be(1),return:be(2)},"function"==typeof Symbol&&(Ae[Symbol.iterator]=function(){return this}),Ae;function be(qe){return function(_t){return function(qe){if(ce)throw new TypeError("Generator is already executing.");for(;se;)try{if(ce=1,le&&(oe=2&qe[0]?le.return:qe[0]?le.throw||((oe=le.return)&&oe.call(le),0):le.next)&&!(oe=oe.call(le,qe[1])).done)return oe;switch(le=0,oe&&(qe=[2&qe[0],oe.value]),qe[0]){case 0:case 1:oe=qe;break;case 4:return se.label++,{value:qe[1],done:!1};case 5:se.label++,le=qe[1],qe=[0];continue;case 7:qe=se.ops.pop(),se.trys.pop();continue;default:if(!(oe=(oe=se.trys).length>0&&oe[oe.length-1])&&(6===qe[0]||2===qe[0])){se=0;continue}if(3===qe[0]&&(!oe||qe[1]>oe[0]&&qe[1]<oe[3])){se.label=qe[1];break}if(6===qe[0]&&se.label<oe[1]){se.label=oe[1],oe=qe;break}if(oe&&se.label<oe[2]){se.label=oe[2],se.ops.push(qe);break}oe[2]&&se.ops.pop(),se.trys.pop();continue}qe=ae.call($,se)}catch(_t){qe=[6,_t],le=0}finally{ce=oe=0}if(5&qe[0])throw qe[1];return{value:qe[0]?qe[1]:void 0,done:!0}}([qe,_t])}}}function R($,ae,se){if(se||2===arguments.length)for(var oe,ce=0,le=ae.length;ce<le;ce++)(oe||!(ce in ae))&&(oe||(oe=Array.prototype.slice.call(ae,0,ce)),oe[ce]=ae[ce]);return $.concat(oe||Array.prototype.slice.call(ae))}},739:function(ue,q,f){"use strict";f.d(q,{l3:function(){return w},_j:function(){return V},LC:function(){return Z},ZN:function(){return O},jt:function(){return b},pV:function(){return T},F4:function(){return S},IO:function(){return k},vP:function(){return I},SB:function(){return A},oB:function(){return D},eR:function(){return v},X$:function(){return N},ZE:function(){return F},k1:function(){return z}});var B=f(14105),U=f(18967),V=function K(){(0,U.Z)(this,K)},Z=function K(){(0,U.Z)(this,K)},w="*";function N(K,j){return{type:7,name:K,definitions:j,options:{}}}function b(K){var j=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return{type:4,styles:j,timings:K}}function I(K){var j=arguments.length>1&&void 0!==arguments[1]?arguments[1]Line truncated
|
||||
@@ -1 +0,0 @@
|
||||
!function(){"use strict";var e,v={},g={};function n(e){var a=g[e];if(void 0!==a)return a.exports;var t=g[e]={id:e,loaded:!1,exports:{}};return v[e].call(t.exports,t,t.exports,n),t.loaded=!0,t.exports}n.m=v,e=[],n.O=function(a,t,u,o){if(!t){var r=1/0;for(i=0;i<e.length;i++){t=e[i][0],u=e[i][1],o=e[i][2];for(var l=!0,f=0;f<t.length;f++)(!1&o||r>=o)&&Object.keys(n.O).every(function(b){return n.O[b](t[f])})?t.splice(f--,1):(l=!1,o<r&&(r=o));if(l){e.splice(i--,1);var s=u();void 0!==s&&(a=s)}}return a}o=o||0;for(var i=e.length;i>0&&e[i-1][2]>o;i--)e[i]=e[i-1];e[i]=[t,u,o]},n.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(a,{a:a}),a},n.d=function(e,a){for(var t in a)n.o(a,t)&&!n.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:a[t]})},n.f={},n.e=function(e){return Promise.all(Object.keys(n.f).reduce(function(a,t){return n.f[t](e,a),a},[]))},n.u=function(e){return e+".77d4bfd104f37c42e028.js"},n.miniCssF=function(e){return"styles.f8555f2eecf8cf87f666.css"},n.hmd=function(e){return(e=Object.create(e)).children||(e.children=[]),Object.defineProperty(e,"exports",{enumerable:!0,set:function(){throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+e.id)}}),e},n.o=function(e,a){return Object.prototype.hasOwnProperty.call(e,a)},function(){var e={},a="gns3-web-ui:";n.l=function(t,u,o,i){if(e[t])e[t].push(u);else{var r,l;if(void 0!==o)for(var f=document.getElementsByTagName("script"),s=0;s<f.length;s++){var c=f[s];if(c.getAttribute("src")==t||c.getAttribute("data-webpack")==a+o){r=c;break}}r||(l=!0,(r=document.createElement("script")).charset="utf-8",r.timeout=120,n.nc&&r.setAttribute("nonce",n.nc),r.setAttribute("data-webpack",a+o),r.src=n.tu(t)),e[t]=[u];var d=function(h,b){r.onerror=r.onload=null,clearTimeout(p);var _=e[t];if(delete e[t],r.parentNode&&r.parentNode.removeChild(r),_&&_.forEach(function(m){return m(b)}),h)return h(b)},p=setTimeout(d.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=d.bind(null,r.onerror),r.onload=d.bind(null,r.onload),l&&document.head.appendChild(r)}}}(),n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},function(){var e;n.tu=function(a){return void 0===e&&(e={createScriptURL:function(t){return t}},"undefined"!=typeof trustedTypes&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("angular#bundler",e))),e.createScriptURL(a)}}(),n.p="",function(){var e={666:0};n.f.j=function(u,o){var i=n.o(e,u)?e[u]:void 0;if(0!==i)if(i)o.push(i[2]);else if(666!=u){var r=new Promise(function(c,d){i=e[u]=[c,d]});o.push(i[2]=r);var l=n.p+n.u(u),f=new Error;n.l(l,function(c){if(n.o(e,u)&&(0!==(i=e[u])&&(e[u]=void 0),i)){var d=c&&("load"===c.type?"missing":c.type),p=c&&c.target&&c.target.src;f.message="Loading chunk "+u+" failed.\n("+d+": "+p+")",f.name="ChunkLoadError",f.type=d,f.request=p,i[1](f)}},"chunk-"+u,u)}else e[u]=0},n.O.j=function(u){return 0===e[u]};var a=function(u,o){var f,s,i=o[0],r=o[1],l=o[2],c=0;for(f in r)n.o(r,f)&&(n.m[f]=r[f]);if(l)var d=l(n);for(u&&u(o);c<i.length;c++)n.o(e,s=i[c])&&e[s]&&e[s][0](),e[i[c]]=0;return n.O(d)},t=self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[];t.forEach(a.bind(null,0)),t.push=a.bind(null,t.push.bind(t))}()}();
|
||||
@@ -0,0 +1 @@
|
||||
!function(){"use strict";var e,v={},g={};function n(e){var u=g[e];if(void 0!==u)return u.exports;var t=g[e]={id:e,loaded:!1,exports:{}};return v[e].call(t.exports,t,t.exports,n),t.loaded=!0,t.exports}n.m=v,e=[],n.O=function(u,t,a,o){if(!t){var r=1/0;for(i=0;i<e.length;i++){t=e[i][0],a=e[i][1],o=e[i][2];for(var l=!0,f=0;f<t.length;f++)(!1&o||r>=o)&&Object.keys(n.O).every(function(b){return n.O[b](t[f])})?t.splice(f--,1):(l=!1,o<r&&(r=o));if(l){e.splice(i--,1);var s=a();void 0!==s&&(u=s)}}return u}o=o||0;for(var i=e.length;i>0&&e[i-1][2]>o;i--)e[i]=e[i-1];e[i]=[t,a,o]},n.n=function(e){var u=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(u,{a:u}),u},n.d=function(e,u){for(var t in u)n.o(u,t)&&!n.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:u[t]})},n.f={},n.e=function(e){return Promise.all(Object.keys(n.f).reduce(function(u,t){return n.f[t](e,u),u},[]))},n.u=function(e){return e+".34a83d9cee7db39cd0de.js"},n.miniCssF=function(e){return"styles.b001e5acc6978e8e4067.css"},n.hmd=function(e){return(e=Object.create(e)).children||(e.children=[]),Object.defineProperty(e,"exports",{enumerable:!0,set:function(){throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+e.id)}}),e},n.o=function(e,u){return Object.prototype.hasOwnProperty.call(e,u)},function(){var e={},u="gns3-web-ui:";n.l=function(t,a,o,i){if(e[t])e[t].push(a);else{var r,l;if(void 0!==o)for(var f=document.getElementsByTagName("script"),s=0;s<f.length;s++){var c=f[s];if(c.getAttribute("src")==t||c.getAttribute("data-webpack")==u+o){r=c;break}}r||(l=!0,(r=document.createElement("script")).charset="utf-8",r.timeout=120,n.nc&&r.setAttribute("nonce",n.nc),r.setAttribute("data-webpack",u+o),r.src=n.tu(t)),e[t]=[a];var d=function(h,b){r.onerror=r.onload=null,clearTimeout(p);var _=e[t];if(delete e[t],r.parentNode&&r.parentNode.removeChild(r),_&&_.forEach(function(m){return m(b)}),h)return h(b)},p=setTimeout(d.bind(null,void 0,{type:"timeout",target:r}),12e4);r.onerror=d.bind(null,r.onerror),r.onload=d.bind(null,r.onload),l&&document.head.appendChild(r)}}}(),n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},function(){var e;n.tu=function(u){return void 0===e&&(e={createScriptURL:function(t){return t}},"undefined"!=typeof trustedTypes&&trustedTypes.createPolicy&&(e=trustedTypes.createPolicy("angular#bundler",e))),e.createScriptURL(u)}}(),n.p="",function(){var e={666:0};n.f.j=function(a,o){var i=n.o(e,a)?e[a]:void 0;if(0!==i)if(i)o.push(i[2]);else if(666!=a){var r=new Promise(function(c,d){i=e[a]=[c,d]});o.push(i[2]=r);var l=n.p+n.u(a),f=new Error;n.l(l,function(c){if(n.o(e,a)&&(0!==(i=e[a])&&(e[a]=void 0),i)){var d=c&&("load"===c.type?"missing":c.type),p=c&&c.target&&c.target.src;f.message="Loading chunk "+a+" failed.\n("+d+": "+p+")",f.name="ChunkLoadError",f.type=d,f.request=p,i[1](f)}},"chunk-"+a,a)}else e[a]=0},n.O.j=function(a){return 0===e[a]};var u=function(a,o){var f,s,i=o[0],r=o[1],l=o[2],c=0;for(f in r)n.o(r,f)&&(n.m[f]=r[f]);if(l)var d=l(n);for(a&&a(o);c<i.length;c++)n.o(e,s=i[c])&&e[s]&&e[s][0](),e[i[c]]=0;return n.O(d)},t=self.webpackChunkgns3_web_ui=self.webpackChunkgns3_web_ui||[];t.forEach(u.bind(null,0)),t.push=u.bind(null,t.push.bind(t))}()}();
|
||||
@@ -0,0 +1,9 @@
|
||||
@charset "UTF-8";
|
||||
/*!
|
||||
* Bootstrap v5.1.3 (https://getbootstrap.com/)
|
||||
* Copyright 2011-2021 The Bootstrap Authors
|
||||
* Copyright 2011-2021 Twitter, Inc.
|
||||
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
||||
*/:root{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13,110,253;--bs-secondary-rgb:108,117,125;--bs-success-rgb:25,135,84;--bs-info-rgb:13,202,240;--bs-warning-rgb:255,193,7;--bs-danger-rgb:220,53,69;--bs-light-rgb:248,249,250;--bs-dark-rgb:33,37,41;--bs-white-rgb:255,255,255;--bs-black-rgb:0,0,0;--bs-body-color-rgb:33,37,41;--bs-body-bg-rgb:255,255,255;--bs-font-sans-serif:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--bs-font-monospace:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--bs-gradient:linear-gradient(180deg,hsla(0,0%,100%,.15),hsla(0,0%,100%,0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-bg:#fff}*,:after,:before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--bs-body-font-family);font-size:1rem;font-size:var(--bs-body-font-size);font-weight:400;font-weight:var(--bs-body-font-weight);line-height:1.5;line-height:var(--bs-body-line-height);color:#212529;color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:#fff;background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}hr{margin:1rem 0;color:inherit;background-color:currentColor;border:0;opacity:.25}hr:not([size]){height:1px}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}.h1,h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width:1200px){.h1,h1{font-size:2.5rem}}.h2,h2{font-size:calc(1.325rem + .9vw)}@media (min-width:1200px){.h2,h2{font-size:2rem}}.h3,h3{font-size:calc(1.3rem + .6vw)}@media (min-width:1200px){.h3,h3{font-size:1.75rem}}.h4,h4{font-size:calc(1.275rem + .3vw)}@media (min-width:1200px){.h4,h4{font-size:1.5rem}}.h5,h5{font-size:1.25rem}.h6,h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[data-bs-original-title],abbr[title]{text-decoration:underline dotted;cursor:help;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}.small,small{font-size:.875em}.mark,mark{padding:.2em;background-color:#fcf8e3}sub,sup{position:relative;font-size:.75em;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#0d6efd;text-decoration:underline}a:hover{color:#0a58ca}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-family:var(--bs-font-monospace);font-size:1em;direction:ltr;unicode-bidi:bidi-override}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:.875em;color:#d63384;word-wrap:break-word}a>code{color:inherit}kbd{padding:.2rem .4rem;font-size:.875em;color:#fff;background-color:#212529;border-radius:.2rem}kbd kbd{padding:0;font-size:1em;font-weight:700}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:.5rem;padding-bottom:.5rem;color:#6c757d;text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}tbody,td,tfoot,th,thead,tr{border:0 solid;border-color:inherit}label{display:inline-block}button{border-radius:0}button:focus:not(:focus-visible){outline:0}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}select:disabled{opacity:1}[list]::-webkit-calendar-picker-indicator{display:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled),button:not(:disabled){cursor:Line truncated
|
||||
/*!*/}@keyframes cdk-text-field-autofill-end{
|
||||
/*!*/}.cdk-text-field-autofill-monitored:-webkit-autofill{animation:cdk-text-field-autofill-start 0s 1ms}.cdk-text-field-autofill-monitored:not(:-webkit-autofill){animation:cdk-text-field-autofill-end 0s 1ms}.mat-focus-indicator,.mat-mdc-focus-indicator{position:relative}.dark-theme{color:#fff!important}.dark-theme .mat-badge{position:relative}.dark-theme .mat-badge-hidden .mat-badge-content{display:none}.dark-theme .mat-badge-content{position:absolute;text-align:center;display:inline-block;border-radius:50%;transition:transform .2s ease-in-out;transform:scale(.6);overflow:hidden;white-space:nowrap;text-overflow:ellipsis;pointer-events:none}.dark-theme .mat-badge-content._mat-animation-noopable,.dark-theme .ng-animate-disabled .mat-badge-content{transition:none}.dark-theme .mat-badge-content.mat-badge-active{transform:none}.dark-theme .mat-badge-small .mat-badge-content{width:16px;height:16px;line-height:16px}.dark-theme .mat-badge-small.mat-badge-above .mat-badge-content{top:-8px}.dark-theme .mat-badge-small.mat-badge-below .mat-badge-content{bottom:-8px}.dark-theme .mat-badge-small.mat-badge-before .mat-badge-content{left:-16px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-before .mat-badge-content{left:auto;right:-16px}.dark-theme .mat-badge-small.mat-badge-after .mat-badge-content{right:-16px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-after .mat-badge-content{right:auto;left:-16px}.dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-8px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-8px}.dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-8px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-8px}.dark-theme .mat-badge-medium .mat-badge-content{width:22px;height:22px;line-height:22px}.dark-theme .mat-badge-medium.mat-badge-above .mat-badge-content{top:-11px}.dark-theme .mat-badge-medium.mat-badge-below .mat-badge-content{bottom:-11px}.dark-theme .mat-badge-medium.mat-badge-before .mat-badge-content{left:-22px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-before .mat-badge-content{left:auto;right:-22px}.dark-theme .mat-badge-medium.mat-badge-after .mat-badge-content{right:-22px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-after .mat-badge-content{right:auto;left:-22px}.dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-11px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-11px}.dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-11px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-11px}.dark-theme .mat-badge-large .mat-badge-content{width:28px;height:28px;line-height:28px}.dark-theme .mat-badge-large.mat-badge-above .mat-badge-content{top:-14px}.dark-theme .mat-badge-large.mat-badge-below .mat-badge-content{bottom:-14px}.dark-theme .mat-badge-large.mat-badge-before .mat-badge-content{left:-28px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-before .mat-badge-content{left:auto;right:-28px}.dark-theme .mat-badge-large.mat-badge-after .mat-badge-content{right:-28px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-after .mat-badge-content{right:auto;left:-28px}.dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-14px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-14px}.dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-14px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-14px}.dark-theme .mat-badge-content{color:#fff;background:#0097a7}.cdk-high-contrast-active .dark-theme .mat-badge-content{outline:1px solid;border-radius:0}.dark-theme .mat-badge-accent .mat-badge-content{background:#b0bec5;color:rgba(0,0,0,.87)}.dark-theme .mat-badge-warn .mat-badge-content{color:#fff;background:#f44336}.dark-theme .mat-badge-disabled .mat-badge-content{background:#677074;color:hsla(0,0%,100%,.5)}.dark-theme .mat-bottom-sheet-container{box-shadow:0 8px 10px -5px rgba(0,0,0,.2),0 16px 24px 2px rgba(0,0,0,.14),0 6px 30px 5px rgba(0,0,0,.12);background:#263238;color:#fff}.mat-button-toggle-appearance-standard .mat-button-toggle-label-content{line-height:48px}.dark-theme .mat-divider{border-top-color:hsla(0,0%,100%,.12)}.dark-theme .mat-divider-vertical{border-right-color:hsla(0,0%,100%,.12)}.mat-expansion-panel-header{height:48px}.mat-expansion-panel-header.mat-expanded{height:64px}.mat-paginator-container{min-height:56px}.mat-horizontal-stepper-header{height:72px}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header,.mat-vertical-stepper-header{padding:24px}.mat-stepper-vertical-line:before{top:-16px;bottom:-16pxLine truncated
|
||||
@@ -1,11 +0,0 @@
|
||||
@charset "UTF-8";
|
||||
/*!
|
||||
* Bootstrap v5.1.3 (https://getbootstrap.com/)
|
||||
* Copyright 2011-2021 The Bootstrap Authors
|
||||
* Copyright 2011-2021 Twitter, Inc.
|
||||
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
||||
*/:root{--bs-blue:#0d6efd;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#dc3545;--bs-orange:#fd7e14;--bs-yellow:#ffc107;--bs-green:#198754;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-white:#fff;--bs-gray:#6c757d;--bs-gray-dark:#343a40;--bs-gray-100:#f8f9fa;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#6c757d;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#212529;--bs-primary:#0d6efd;--bs-secondary:#6c757d;--bs-success:#198754;--bs-info:#0dcaf0;--bs-warning:#ffc107;--bs-danger:#dc3545;--bs-light:#f8f9fa;--bs-dark:#212529;--bs-primary-rgb:13,110,253;--bs-secondary-rgb:108,117,125;--bs-success-rgb:25,135,84;--bs-info-rgb:13,202,240;--bs-warning-rgb:255,193,7;--bs-danger-rgb:220,53,69;--bs-light-rgb:248,249,250;--bs-dark-rgb:33,37,41;--bs-white-rgb:255,255,255;--bs-black-rgb:0,0,0;--bs-body-color-rgb:33,37,41;--bs-body-bg-rgb:255,255,255;--bs-font-sans-serif:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--bs-font-monospace:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--bs-gradient:linear-gradient(180deg,hsla(0,0%,100%,.15),hsla(0,0%,100%,0));--bs-body-font-family:var(--bs-font-sans-serif);--bs-body-font-size:1rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#212529;--bs-body-bg:#fff}*,:after,:before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--bs-body-font-family);font-size:1rem;font-size:var(--bs-body-font-size);font-weight:400;font-weight:var(--bs-body-font-weight);line-height:1.5;line-height:var(--bs-body-line-height);color:#212529;color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:#fff;background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}hr{margin:1rem 0;color:inherit;background-color:currentColor;border:0;opacity:.25}hr:not([size]){height:1px}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}.h1,h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width:1200px){.h1,h1{font-size:2.5rem}}.h2,h2{font-size:calc(1.325rem + .9vw)}@media (min-width:1200px){.h2,h2{font-size:2rem}}.h3,h3{font-size:calc(1.3rem + .6vw)}@media (min-width:1200px){.h3,h3{font-size:1.75rem}}.h4,h4{font-size:calc(1.275rem + .3vw)}@media (min-width:1200px){.h4,h4{font-size:1.5rem}}.h5,h5{font-size:1.25rem}.h6,h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[data-bs-original-title],abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;-webkit-text-decoration-skip-ink:none;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}.small,small{font-size:.875em}.mark,mark{padding:.2em;background-color:#fcf8e3}sub,sup{position:relative;font-size:.75em;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#0d6efd;text-decoration:underline}a:hover{color:#0a58ca}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-family:var(--bs-font-monospace);font-size:1em;direction:ltr;unicode-bidi:bidi-override}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:.875em;color:#d63384;word-wrap:break-word}a>code{color:inherit}kbd{padding:.2rem .4rem;font-size:.875em;color:#fff;background-color:#212529;border-radius:.2rem}kbd kbd{padding:0;font-size:1em;font-weight:700}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:.5rem;padding-bottom:.5rem;color:#6c757d;text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}tbody,td,tfoot,th,thead,tr{border:0 solid;border-color:inherit}label{display:inline-block}button{border-radius:0}button:focus:not(:focus-visible){outline:0}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}select:disabled{opacity:1}[list]::-webkit-calendar-picker-indicator{display:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=rLine truncated
|
||||
/*!*/}@keyframes cdk-text-field-autofill-start{
|
||||
/*!*/}@-webkit-keyframes cdk-text-field-autofill-end{
|
||||
/*!*/}@keyframes cdk-text-field-autofill-end{
|
||||
/*!*/}.cdk-text-field-autofill-monitored:-webkit-autofill{-webkit-animation:cdk-text-field-autofill-start 0s 1ms;animation:cdk-text-field-autofill-start 0s 1ms}.cdk-text-field-autofill-monitored:not(:-webkit-autofill){-webkit-animation:cdk-text-field-autofill-end 0s 1ms;animation:cdk-text-field-autofill-end 0s 1ms}.mat-focus-indicator,.mat-mdc-focus-indicator{position:relative}.dark-theme{color:#fff!important}.dark-theme .mat-badge{position:relative}.dark-theme .mat-badge-hidden .mat-badge-content{display:none}.dark-theme .mat-badge-content{position:absolute;text-align:center;display:inline-block;border-radius:50%;transition:transform .2s ease-in-out;transform:scale(.6);overflow:hidden;white-space:nowrap;text-overflow:ellipsis;pointer-events:none}.dark-theme .mat-badge-content._mat-animation-noopable,.dark-theme .ng-animate-disabled .mat-badge-content{transition:none}.dark-theme .mat-badge-content.mat-badge-active{transform:none}.dark-theme .mat-badge-small .mat-badge-content{width:16px;height:16px;line-height:16px}.dark-theme .mat-badge-small.mat-badge-above .mat-badge-content{top:-8px}.dark-theme .mat-badge-small.mat-badge-below .mat-badge-content{bottom:-8px}.dark-theme .mat-badge-small.mat-badge-before .mat-badge-content{left:-16px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-before .mat-badge-content{left:auto;right:-16px}.dark-theme .mat-badge-small.mat-badge-after .mat-badge-content{right:-16px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-after .mat-badge-content{right:auto;left:-16px}.dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-8px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-8px}.dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-8px}[dir=rtl] .dark-theme .mat-badge-small.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-8px}.dark-theme .mat-badge-medium .mat-badge-content{width:22px;height:22px;line-height:22px}.dark-theme .mat-badge-medium.mat-badge-above .mat-badge-content{top:-11px}.dark-theme .mat-badge-medium.mat-badge-below .mat-badge-content{bottom:-11px}.dark-theme .mat-badge-medium.mat-badge-before .mat-badge-content{left:-22px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-before .mat-badge-content{left:auto;right:-22px}.dark-theme .mat-badge-medium.mat-badge-after .mat-badge-content{right:-22px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-after .mat-badge-content{right:auto;left:-22px}.dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-11px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-11px}.dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-11px}[dir=rtl] .dark-theme .mat-badge-medium.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-11px}.dark-theme .mat-badge-large .mat-badge-content{width:28px;height:28px;line-height:28px}.dark-theme .mat-badge-large.mat-badge-above .mat-badge-content{top:-14px}.dark-theme .mat-badge-large.mat-badge-below .mat-badge-content{bottom:-14px}.dark-theme .mat-badge-large.mat-badge-before .mat-badge-content{left:-28px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-before .mat-badge-content{left:auto;right:-28px}.dark-theme .mat-badge-large.mat-badge-after .mat-badge-content{right:-28px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-after .mat-badge-content{right:auto;left:-28px}.dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-before .mat-badge-content{left:-14px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-before .mat-badge-content{left:auto;right:-14px}.dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-after .mat-badge-content{right:-14px}[dir=rtl] .dark-theme .mat-badge-large.mat-badge-overlap.mat-badge-after .mat-badge-content{right:auto;left:-14px}.dark-theme .mat-badge-content{color:#fff;background:#0097a7}.cdk-high-contrast-active .dark-theme .mat-badge-content{outline:1px solid;border-radius:0}.dark-theme .mat-badge-accent .mat-badge-content{background:#b0bec5;color:rgba(0,0,0,.87)}.dark-theme .mat-badge-warn .mat-badge-content{color:#fff;background:#f44336}.dark-theme .mat-badge-disabled .mat-badge-content{background:#677074;color:hsla(0,0%,100%,.5)}.dark-theme .mat-bottom-sheet-container{box-shadow:0 8px 10px -5px rgba(0,0,0,.2),0 16px 24px 2px rgba(0,0,0,.14),0 6px 30px 5px rgba(0,0,0,.12);background:#263238;color:#fff}.mat-button-toggle-appearance-standard .mat-button-toggle-label-content{line-height:48px}.dark-theme .mat-divider{border-top-color:hsla(0,0%,100%,.12)}.dark-theme .mat-divider-vertical{border-right-color:hsla(0,0%,100%,.12)}.mat-expansion-panel-header{height:48px}.mat-expansion-panel-header.mat-expanded{height:64px}.mat-paginator-container{min-height:56px}.mat-horizontal-stepper-header{height:72px}.mat-stepper-label-position-bottom .mat-horizontal-steppLine truncated
|
||||
@@ -215,7 +215,7 @@ class AsyncioTelnetServer:
|
||||
await self._write_intro(network_writer, echo=self._echo, binary=self._binary, naws=self._naws)
|
||||
await connection.connected()
|
||||
await self._process(network_reader, network_writer, connection)
|
||||
except ConnectionError:
|
||||
except (ConnectionError, OSError):
|
||||
async with self._lock:
|
||||
network_writer.close()
|
||||
# await network_writer.wait_closed() # this doesn't work in Python 3.6
|
||||
@@ -308,14 +308,15 @@ class AsyncioTelnetServer:
|
||||
|
||||
# Replicate the output on all clients
|
||||
for connection_key in list(self._connections.keys()):
|
||||
client_info = connection_key.get_extra_info("socket").getpeername()
|
||||
connection = self._connections[connection_key]
|
||||
client_info = None
|
||||
|
||||
try:
|
||||
client_info = connection_key.get_extra_info("socket").getpeername()
|
||||
connection.writer.write(data)
|
||||
await asyncio.wait_for(connection.writer.drain(), timeout=10)
|
||||
except:
|
||||
log.debug(f"Timeout while sending data to client: {client_info}, closing and removing from connection table.")
|
||||
except (OSError, ConnectionError, asyncio.TimeoutError) as e:
|
||||
log.debug(f"Error sending data to client {client_info}: {e}, closing and removing from connection table.")
|
||||
connection.close()
|
||||
del self._connections[connection_key]
|
||||
|
||||
|
||||
@@ -23,8 +23,8 @@
|
||||
# or negative for a release candidate or beta (after the base version
|
||||
# number has been incremented)
|
||||
|
||||
__version__ = "2.2.56.1"
|
||||
__version_info__ = (2, 2, 56, 0)
|
||||
__version__ = "2.2.58"
|
||||
__version_info__ = (2, 2, 58, 0)
|
||||
|
||||
if "dev" in __version__:
|
||||
try:
|
||||
|
||||
@@ -126,7 +126,7 @@ class Route(object):
|
||||
response.set_status(401)
|
||||
response.headers["WWW-Authenticate"] = 'Basic realm="GNS3 server"'
|
||||
# Force close the keep alive. Work around a Qt issue where Qt timeout instead of handling the 401
|
||||
# this happen only for the first query send by the client.
|
||||
# this happens only for the first query send by the client.
|
||||
response.force_close()
|
||||
return response
|
||||
|
||||
|
||||
@@ -251,7 +251,7 @@ async def test_install_busybox_dynamic_linked():
|
||||
mock_process.communicate = AsyncioMagicMock(return_value=(b"Dynamically linked library", b""))
|
||||
|
||||
with patch("os.path.isfile", return_value=False):
|
||||
with patch("gns3server.compute.docker.shutil.which", return_value="/usr/bin/busybox"):
|
||||
with patch("gns3server.compute.docker.shutil.which", side_effect=lambda name: "/usr/bin/busybox" if name == "busybox" else None):
|
||||
with asyncio_patch("gns3server.compute.docker.asyncio.create_subprocess_exec", return_value=mock_process):
|
||||
with pytest.raises(DockerError) as e:
|
||||
dst_dir = Docker.resources_path()
|
||||
|
||||
@@ -262,7 +262,7 @@ def test_create_netmap_config(vm):
|
||||
|
||||
async def test_build_command(vm):
|
||||
|
||||
assert await vm._build_command() == [vm.path, str(vm.application_id)]
|
||||
assert await vm._build_command() == [vm.path, "-n", "256", "-m", "1024", str(vm.application_id)]
|
||||
|
||||
|
||||
def test_get_startup_config(vm):
|
||||
|
||||
@@ -68,7 +68,6 @@ def test_exportable_files():
|
||||
assert not _is_exportable("project-files/tmp")
|
||||
assert not _is_exportable("project-files/test_log.txt")
|
||||
assert not _is_exportable("project-files/test.log")
|
||||
assert not _is_exportable("test/snapshots")
|
||||
assert not _is_exportable("test/project-files/snapshots")
|
||||
assert not _is_exportable("test/project-files/snapshots/test.gns3p")
|
||||
|
||||
|
||||
@@ -132,6 +132,13 @@ def test_list_ports_port_name_format(node):
|
||||
assert node.__json__()["ports"][1]["name"] == "eth0/0"
|
||||
|
||||
|
||||
def test_short_name_none():
|
||||
"""
|
||||
Test short_name does not raise exception when name is None
|
||||
"""
|
||||
assert EthernetPort(None, 0, 0, 0).short_name is None
|
||||
|
||||
|
||||
def test_list_ports_adapters(node):
|
||||
"""
|
||||
List port using adapters properties
|
||||
|
||||
@@ -16,22 +16,16 @@
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import os
|
||||
import pytest
|
||||
from unittest.mock import patch, MagicMock
|
||||
from uuid import uuid4
|
||||
|
||||
from gns3server.controller.project import Project
|
||||
import pytest
|
||||
from unittest import mock
|
||||
from unittest.mock import patch, MagicMock
|
||||
from gns3server.controller.snapshot import Snapshot
|
||||
|
||||
from tests.utils import AsyncioMagicMock
|
||||
|
||||
|
||||
# @pytest.fixture
|
||||
# def project(controller):
|
||||
# project = Project(controller=controller, name="Test")
|
||||
# controller._projects[project.id] = project
|
||||
# return project
|
||||
|
||||
|
||||
def test_snapshot_name(project):
|
||||
"""
|
||||
Test create a snapshot object with a name
|
||||
@@ -40,12 +34,7 @@ def test_snapshot_name(project):
|
||||
snapshot = Snapshot(project, name="test1")
|
||||
assert snapshot.name == "test1"
|
||||
assert snapshot._created_at > 0
|
||||
assert snapshot.path.startswith(os.path.join(project.path, "snapshots", "test1_"))
|
||||
assert snapshot.path.endswith(".gns3project")
|
||||
|
||||
# Check if UTC conversion doesn't corrupt the path
|
||||
snap2 = Snapshot(project, filename=os.path.basename(snapshot.path))
|
||||
assert snap2.path == snapshot.path
|
||||
assert snapshot.path == os.path.join(project.path, "snapshots", "test1.gns3snapshot")
|
||||
|
||||
|
||||
def test_snapshot_filename(project):
|
||||
@@ -53,22 +42,44 @@ def test_snapshot_filename(project):
|
||||
Test create a snapshot object with a filename
|
||||
"""
|
||||
|
||||
# legacy snapshot
|
||||
snapshot = Snapshot(project, filename="test1_260716_100439.gns3project")
|
||||
assert snapshot.name == "test1"
|
||||
assert snapshot._created_at == 1469527479.0
|
||||
assert snapshot._created_at == 1469527479
|
||||
assert snapshot.path == os.path.join(project.path, "snapshots", "test1_260716_100439.gns3project")
|
||||
|
||||
# new style snapshot
|
||||
snapshot_id = str(uuid4())
|
||||
snapshot = Snapshot(project, snapshot_id=snapshot_id, name="test2", created_at=1469527479)
|
||||
assert snapshot.id == snapshot_id
|
||||
assert snapshot.name == "test2"
|
||||
assert snapshot.path == os.path.join(project.path, "snapshots", "test2.gns3snapshot")
|
||||
assert snapshot._created_at == 1469527479
|
||||
|
||||
|
||||
def test_json(project):
|
||||
|
||||
# legacy snapshot
|
||||
snapshot = Snapshot(project, filename="snapshot_test_260716_100439.gns3project")
|
||||
assert snapshot.__json__() == {
|
||||
"snapshot_id": snapshot._id,
|
||||
"name": "snapshot_test",
|
||||
"project_id": project.id,
|
||||
"description": "Snapshot 'snapshot_test' taken on 2016-07-26 at 10:04:39",
|
||||
"filename": "snapshot_test_260716_100439.gns3project",
|
||||
"created_at": 1469527479
|
||||
}
|
||||
|
||||
# new style snapshot
|
||||
snapshot = Snapshot(project, name="snapshot_test2")
|
||||
assert snapshot.__json__() == {
|
||||
"snapshot_id": snapshot._id,
|
||||
"name": "snapshot_test2",
|
||||
"project_id": project.id,
|
||||
"filename": "snapshot_test2.gns3snapshot",
|
||||
"description": mock.ANY,
|
||||
"created_at": mock.ANY
|
||||
}
|
||||
|
||||
def test_invalid_snapshot_filename(project):
|
||||
|
||||
@@ -85,7 +96,8 @@ async def test_restore(project, controller):
|
||||
response.json = {"console": 2048}
|
||||
compute.post = AsyncioMagicMock(return_value=response)
|
||||
|
||||
await project.add_node(compute, "test1", None, node_type="vpcs", properties={"startup_config": "test.cfg"})
|
||||
node1_id = str(uuid4())
|
||||
await project.add_node(compute, "test1", node1_id, node_type="vpcs", properties={"startup_config": "test.cfg"})
|
||||
snapshot = await project.snapshot(name="test")
|
||||
|
||||
# We add a node after the snapshots
|
||||
@@ -103,8 +115,11 @@ async def test_restore(project, controller):
|
||||
with patch("gns3server.config.Config.get_section_config", return_value={"local": True}):
|
||||
await snapshot.restore()
|
||||
|
||||
# make sure the original node IDs are restored
|
||||
assert list(project.nodes.keys())[0] == node1_id
|
||||
|
||||
assert "snapshot.restored" in [c[0][0] for c in controller.notification.project_emit.call_args_list]
|
||||
# project.closed notification should not be send when restoring snapshots
|
||||
# project.closed notification should not be sent when restoring snapshots
|
||||
assert "project.closed" not in [c[0][0] for c in controller.notification.project_emit.call_args_list]
|
||||
|
||||
project = controller.get_project(project.id)
|
||||
|
||||
@@ -69,8 +69,8 @@ async def test_iou_create(compute_api, compute_project, base_params):
|
||||
assert response.json["project_id"] == compute_project.id
|
||||
assert response.json["serial_adapters"] == 2
|
||||
assert response.json["ethernet_adapters"] == 2
|
||||
assert response.json["ram"] == 256
|
||||
assert response.json["nvram"] == 128
|
||||
assert response.json["ram"] == 1024
|
||||
assert response.json["nvram"] == 256
|
||||
assert response.json["l1_keepalives"] is False
|
||||
|
||||
|
||||
@@ -130,8 +130,8 @@ async def test_iou_get(compute_api, compute_project, vm):
|
||||
assert response.json["project_id"] == compute_project.id
|
||||
assert response.json["serial_adapters"] == 2
|
||||
assert response.json["ethernet_adapters"] == 2
|
||||
assert response.json["ram"] == 256
|
||||
assert response.json["nvram"] == 128
|
||||
assert response.json["ram"] == 1024
|
||||
assert response.json["nvram"] == 256
|
||||
assert response.json["l1_keepalives"] is False
|
||||
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@ import json
|
||||
|
||||
from unittest.mock import patch, MagicMock
|
||||
from tests.utils import asyncio_patch
|
||||
from gns3server.controller.node import Node
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
@@ -34,6 +35,14 @@ async def project(controller_api, controller):
|
||||
return controller.get_project(u)
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def node(project, compute):
|
||||
|
||||
node = Node(project, compute, "test", node_type="vpcs")
|
||||
project._nodes[node.id] = node
|
||||
return node
|
||||
|
||||
|
||||
async def test_create_project_with_path(controller_api, tmpdir):
|
||||
|
||||
response = await controller_api.post("/projects", {"name": "test", "path": str(tmpdir), "project_id": "00010203-0405-0607-0809-0a0b0c0d0e0f"})
|
||||
@@ -295,7 +304,7 @@ async def test_export_without_images(controller_api, tmpdir, project):
|
||||
with myzip.open("a") as myfile:
|
||||
content = myfile.read()
|
||||
assert content == b"hello"
|
||||
# Image should not exported
|
||||
# Images should not be exported
|
||||
with pytest.raises(KeyError):
|
||||
myzip.getinfo("images/IOS/test.image")
|
||||
|
||||
@@ -356,8 +365,14 @@ async def test_import(controller_api, tmpdir, controller):
|
||||
assert content == "hello"
|
||||
|
||||
|
||||
async def test_duplicate(controller_api, project):
|
||||
async def test_duplicate(controller_api, controller, project, node):
|
||||
|
||||
response = await controller_api.post("/projects/{project_id}/duplicate".format(project_id=project.id), {"name": "hello"})
|
||||
response = await controller_api.post("/projects/{project_id}/duplicate".format(project_id=project.id), {"name": "duplicated_project"})
|
||||
assert response.status == 201
|
||||
assert response.json["name"] == "hello"
|
||||
assert response.json["name"] == "duplicated_project"
|
||||
duplicated_project_id = response.json["project_id"]
|
||||
assert duplicated_project_id != project.id # a new project_id should have been generated
|
||||
duplicated_project = controller.get_project(duplicated_project_id)
|
||||
with open(os.path.join(duplicated_project.path, "duplicated_project.gns3")) as f:
|
||||
duplicated_topology = json.load(f)
|
||||
assert duplicated_topology["topology"]["nodes"][0]["node_id"] != node.id # a new node_id should have been generated
|
||||
@@ -57,10 +57,11 @@ async def test_restore_snapshot(controller_api, project, snapshot):
|
||||
response = await controller_api.post("/projects/{}/snapshots/{}/restore".format(project.id, snapshot.id))
|
||||
assert response.status == 201
|
||||
assert response.json["name"] == project.name
|
||||
assert response.json["project_id"] == project.id
|
||||
|
||||
|
||||
async def test_create_snapshot(controller_api, project):
|
||||
|
||||
response = await controller_api.post("/projects/{}/snapshots".format(project.id), {"name": "snap1"})
|
||||
assert response.status == 201
|
||||
assert len(os.listdir(os.path.join(project.path, "snapshots"))) == 1
|
||||
assert len(os.listdir(os.path.join(project.path, "snapshots"))) == 2
|
||||
@@ -592,14 +592,14 @@ async def test_iou_template_create(controller_api):
|
||||
"default_name_format": "IOU{0}",
|
||||
"ethernet_adapters": 2,
|
||||
"name": "IOU template",
|
||||
"nvram": 128,
|
||||
"nvram": 256,
|
||||
"path": "/path/to/i86bi_linux-ipbase-ms-12.4.bin",
|
||||
"private_config": "",
|
||||
"ram": 256,
|
||||
"ram": 1024,
|
||||
"serial_adapters": 2,
|
||||
"startup_config": "iou_l3_base_startup-config.txt",
|
||||
"symbol": ":/symbols/multilayer_switch.svg",
|
||||
"use_default_iou_values": True,
|
||||
"use_default_iou_values": False,
|
||||
"l1_keepalives": False}
|
||||
|
||||
for item, value in expected_response.items():
|
||||
|
||||
Reference in new issue
Block a user