Skip to content

Commit c5a2e1f

Browse files
authored
doc: Add more content to documentation website (#111)
1 parent 4401029 commit c5a2e1f

File tree

9 files changed

+151
-24
lines changed

9 files changed

+151
-24
lines changed

docs/README.md

+1-12
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,7 @@ pip install eos-downloader
2121
ardl --token <your-token> get eos --format 64 --latest --release-type M
2222
```
2323

24-
> [!NOTE]
25-
> The main branch is not the stable branch and can be broken between releases. It is safe to consider using tags for stable versions. All versions on pypi servers are considered stable.
26-
27-
## FAQ
28-
29-
On EVE-NG, you may have to install/upgrade __pyOpenSSL__ in version `23.0.0`:
30-
31-
```bash
32-
# Error when running ardl: AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'
33-
34-
$ pip install pyopenssl --upgrade
35-
```
24+
<img src='imgs/readme.webp' width="800" height="600" class="center" />
3625

3726
## Author
3827

docs/api/defaults.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
## ::: eos_downloader.defaults

docs/faq.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Frequently Asked Questions
2+
3+
## EVE-NG with OpenSSL issue.
4+
5+
On EVE-NG, you may have to install/upgrade __pyOpenSSL__ in version `23.0.0`:
6+
7+
```bash
8+
# Error when running ardl: AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'
9+
10+
$ pip install pyopenssl --upgrade
11+
```

docs/imgs/readme.webp

448 KB
Binary file not shown.

docs/stylesheets/extra.material.css

+8
Original file line numberDiff line numberDiff line change
@@ -243,3 +243,11 @@ h5.doc-heading {
243243
/* Avoid to capitalize h5 headers for mkdocstrings */
244244
text-transform: none;
245245
}
246+
247+
248+
.center {
249+
display: block;
250+
margin-left: auto;
251+
margin-right: auto;
252+
/* width: 50%; */
253+
}

docs/usage/cvp.md

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Download CloudVision package from arista website
2+
3+
This command gives you option to download EOS images localy. Some options are available based on image type like importing your cEOS container in your local registry
4+
5+
```bash
6+
# Get latest version of CVP in Vvmware format
7+
ardl get cvp --latest --format ova
8+
9+
# Get latest version of CVP in upgrade format
10+
ardl get eos --branch 4.29 --format upgrade
11+
```
12+
13+
## ardl get eos options
14+
15+
Below are all the options available to get EOS package:
16+
17+
```bash
18+
$ ardl get cvp --help
19+
Usage: ardl get cvp [OPTIONS]
20+
21+
Download CVP image from Arista server.
22+
23+
Options:
24+
--format TEXT Image format [default: ova]
25+
--output PATH Path to save image [default: .]
26+
--latest Get latest version. If --branch is not use, get the latest
27+
branch with specific release type
28+
--version TEXT EOS version to download
29+
--branch TEXT Branch to download
30+
--dry-run Enable dry-run mode: only run code without system changes
31+
--help Show this message and exit.
32+
```
33+
34+
!!! info
35+
You can get information about available version using the [`ardl info version` cli](./info.md)

docs/usage/mapping.md

+77
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# Get information about software mapping
2+
3+
`ardl` comes with a tool to get all supoprted package format for both CVP and EOS softwares. It helps to know which format to use for a specific file extension.
4+
5+
## Get information about available versions
6+
7+
```bash
8+
$ ardl info mapping --help
9+
Usage: ardl info mapping [OPTIONS]
10+
11+
List available flavors of Arista packages (eos or CVP) packages.
12+
13+
Options:
14+
--package [eos|cvp]
15+
--format [json|text|fancy] Output format
16+
--details Show details for each flavor
17+
--help Show this message and exit.
18+
```
19+
20+
## Usage example
21+
22+
With this CLI, you can specify either a branch or a release type when applicable to filter information:
23+
24+
25+
```bash
26+
# Get list of supported packages for EOS.
27+
$ ardl info mapping --package eos
28+
Log Level is: error
29+
30+
╭─────────────────────────── Flavors ───────────────╮
31+
│ │
32+
* Flavor: 64 │
33+
* Flavor: INT │
34+
* Flavor: 2GB-INT │
35+
* Flavor: cEOS │
36+
* Flavor: cEOS64 │
37+
* Flavor: vEOS │
38+
* Flavor: vEOS-lab │
39+
* Flavor: EOS-2GB │
40+
* Flavor: RN │
41+
* Flavor: SOURCE │
42+
* Flavor: default │
43+
│ │
44+
╰───────────────────────────────────────────────────╯
45+
46+
# Get list of supported packages for EOS with filename information
47+
$ ardl info mapping --package eos
48+
Log Level is: error
49+
50+
╭─────────────────────────────────────────────────── Flavors ─────────╮
51+
│ │
52+
* Flavor: 64 │
53+
│ - Information: extension='.swi' prepend='EOS64'
54+
* Flavor: INT │
55+
│ - Information: extension='-INT.swi' prepend='EOS'
56+
* Flavor: 2GB-INT │
57+
│ - Information: extension='-INT.swi' prepend='EOS-2GB'
58+
* Flavor: cEOS │
59+
│ - Information: extension='.tar.xz' prepend='cEOS-lab'
60+
* Flavor: cEOS64 │
61+
│ - Information: extension='.tar.xz' prepend='cEOS64-lab'
62+
* Flavor: vEOS │
63+
│ - Information: extension='.vmdk' prepend='vEOS'
64+
* Flavor: vEOS-lab │
65+
│ - Information: extension='.vmdk' prepend='vEOS-lab'
66+
* Flavor: EOS-2GB │
67+
│ - Information: extension='.swi' prepend='EOS-2GB'
68+
* Flavor: RN │
69+
│ - Information: extension='-' prepend='RN'
70+
* Flavor: SOURCE │
71+
│ - Information: extension='-source.tar' prepend='EOS'
72+
* Flavor: default │
73+
│ - Information: extension='.swi' prepend='EOS'
74+
│ │
75+
╰─────────────────────────────────────────────────────────────────────╯
76+
77+
```

eos_downloader/defaults.py

+14-12
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,23 @@
11
# coding: utf-8 -*-
2-
"""Default values for eos_downloader.
2+
"""
3+
Default values for eos_downloader.
34
45
This module contains default configuration values used by the eos_downloader package.
56
6-
Constants:
7-
DEFAULT_REQUEST_HEADERS (dict): Default HTTP headers used for API requests
8-
Contains Content-Type and User-Agent headers
9-
10-
DEFAULT_SOFTWARE_FOLDER_TREE (str): API endpoint URL for retrieving the EOS software folder structure
11-
12-
DEFAULT_DOWNLOAD_URL (str): API endpoint URL for getting download links for EOS images
13-
14-
DEFAULT_SERVER_SESSION (str): API endpoint URL for obtaining session codes from Arista's servers
7+
Attributes
8+
----------
9+
DEFAULT_REQUEST_HEADERS : dict
10+
Default HTTP headers used for API requests. Contains Content-Type and User-Agent headers.
11+
DEFAULT_SOFTWARE_FOLDER_TREE : str
12+
API endpoint URL for retrieving the EOS software folder structure.
13+
DEFAULT_DOWNLOAD_URL : str
14+
API endpoint URL for getting download links for EOS images.
15+
DEFAULT_SERVER_SESSION : str
16+
API endpoint URL for obtaining session codes from Arista's servers.
17+
EVE_QEMU_FOLDER_PATH : str
18+
Path to the folder where the downloaded EOS images will be stored on an EVE-NG server.
1519
"""
1620

17-
1821
DEFAULT_REQUEST_HEADERS = {
1922
"Content-Type": "application/json",
2023
"User-Agent": "Chrome/123.0.0.0",
@@ -27,5 +30,4 @@
2730

2831
DEFAULT_SERVER_SESSION = "https://www.arista.com/custom_data/api/cvp/getSessionCode/"
2932

30-
# Path to the folder where the downloaded EOS images will be stored on an EVE-NG server.
3133
EVE_QEMU_FOLDER_PATH = "/opt/unetlab/addons/qemu/"

mkdocs.yml

+4
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,9 @@ nav:
163163
- Home: README.md
164164
- Usage:
165165
- Get EOS package: usage/eos.md
166+
- Get CVP package: usage/cvp.md
166167
- Version information: usage/info.md
168+
- Software mapping: usage/mapping.md
167169
- Code documentation:
168170
- Models:
169171
- Version: api/models/version.md
@@ -174,4 +176,6 @@ nav:
174176
- Arista XML API: api/logics/arista_xml_server.md
175177
- Download Management: api/logics/download.md
176178
- Helpers: api/helpers.md
179+
- Defaults: api/defaults.md
180+
- FAQ: faq.md
177181

0 commit comments

Comments
 (0)