Merging upstream version 0.12.0.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
f45bc3d463
commit
8d2f70e3c7
77 changed files with 23610 additions and 2331 deletions
37
docs/usage/cvp.md
Normal file
37
docs/usage/cvp.md
Normal file
|
@ -0,0 +1,37 @@
|
|||
# Download CloudVision package from arista website
|
||||
|
||||
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
|
||||
|
||||
```bash
|
||||
# Get latest version of CVP in Vvmware format
|
||||
ardl get cvp --latest --format ova
|
||||
|
||||
# Get latest version of CVP in upgrade format
|
||||
ardl get eos --branch 4.29 --format upgrade
|
||||
```
|
||||
|
||||
## ardl get eos options
|
||||
|
||||
Below are all the options available to get EOS package:
|
||||
|
||||
```bash
|
||||
$ ardl get cvp --help
|
||||
Usage: ardl get cvp [OPTIONS]
|
||||
|
||||
Download CVP image from Arista server.
|
||||
|
||||
Options:
|
||||
--format TEXT Image format [env var: ARISTA_GET_CVP_FORMAT; default: ova]
|
||||
--output PATH Path to save image [env var: ARISTA_GET_CVP_OUTPUT;
|
||||
default: .]
|
||||
--latest Get latest version. If --branch is not use, get the latest
|
||||
branch with specific release type [env var:
|
||||
ARISTA_GET_CVP_LATEST]
|
||||
--version TEXT EOS version to download [env var: ARISTA_GET_CVP_VERSION]
|
||||
--branch TEXT Branch to download [env var: ARISTA_GET_CVP_BRANCH]
|
||||
--dry-run Enable dry-run mode: only run code without system changes
|
||||
--help
|
||||
```
|
||||
|
||||
!!! info
|
||||
You can get information about available version using the [`ardl info version` cli](./info.md)
|
71
docs/usage/environment.md
Normal file
71
docs/usage/environment.md
Normal file
|
@ -0,0 +1,71 @@
|
|||
# Environment Variables in eos-downloader
|
||||
|
||||
## Overview
|
||||
|
||||
`ardl` is able to read environment variables to replace cli option to make it easier to work with in workflow. Even if all cli options can be replaced by environment variables, here are the most useful ones:
|
||||
|
||||
Standard rule for these variables is:
|
||||
|
||||
```bash
|
||||
# root command
|
||||
ARISTA_<OPTION_NAME>
|
||||
|
||||
# First Level command
|
||||
ARISTA_<COMMAND_NAME>_<OPTION_NAME>
|
||||
|
||||
# Second level command
|
||||
ARISTA_<COMMAND_NAME>_<COMMAND_NAME>_<OPTION_NAME>
|
||||
```
|
||||
|
||||
!!! TIP "How to get variable names"
|
||||
Standard _ENV_ variables are exposed in cli help and are visible with `[env var: ARISTA_GET_EOS_DOCKER_TAG]`
|
||||
|
||||
## Standard Variables
|
||||
|
||||
__Generic Options__:
|
||||
|
||||
- __ARISTA_TOKEN__ (`ardl --token`): Load your token and avoid to print your token in clear text during a workflow.
|
||||
|
||||
__EOS Options__:
|
||||
|
||||
- __ARISTA_GET_EOS_FORMAT__ (`ardl get eos --format`): Image format
|
||||
- __ARISTA_GET_EOS_OUTPUT__ (`ardl get eos --output`): Path to save EOS image.
|
||||
- __ARISTA_GET_EOS_VERSION__ (`ardl get eos --version`): Version to download from Arista server
|
||||
- __ARISTA_GET_EOS_BRANCH__ (`ardl get eos --latest`): Flag to retrieve latest version available from arista server.
|
||||
- __ARISTA_GET_EOS_BRANCH__ (`ardl get eos --branch`): Branch to download
|
||||
- __ARISTA_GET_EOS_EVE_NG__ (`ardl get eos --eve-ng`): Run EVE-NG vEOS provisioning (only if CLI runs on an EVE-NG server).
|
||||
- __ARISTA_GET_EOS_DOCKER_NAME__ (`ardl get eos --docker-name`): Docker image name when importing cEOS.
|
||||
- __ARISTA_GET_EOS_DOCKER_TAG__ (`ardl get eos --docker-tag`): Docker tag to use when cEOS image is imported in Docker.
|
||||
- __ARISTA_GET_EOS_RELEASE_TYPE__ (`ardl get eos --release-type`): Release type (M for Maintenance, F for Feature)
|
||||
|
||||
__CVP options__:
|
||||
|
||||
- __ARISTA_GET_CVP_FORMAT__ (`ardl get cvp --format`): Image format
|
||||
- __ARISTA_GET_CVP_OUTPUT__ (`ardl get cvp --output`): Path to save CVP image.
|
||||
- __ARISTA_GET_CVP_LATEST__ (`ardl get cvp --latest`): Flag to retrieve latest version available from arista server.
|
||||
- __ARISTA_GET_CVP_VERSION__ (`ardl get cvp --version`): Version to download from Arista server
|
||||
- __ARISTA_GET_CVP_BRANCH__ (`ardl get cvp --branch`): Branch to download
|
||||
|
||||
|
||||
## Usage examples
|
||||
|
||||
- Basic usage with `export`
|
||||
|
||||
```bash
|
||||
# Use token from env variables
|
||||
export ARISTA_TOKEN=1234567890
|
||||
ardl info versions --branch 4.29
|
||||
```
|
||||
|
||||
- Usage with direnv
|
||||
|
||||
```bash
|
||||
cat .envrc
|
||||
export ARISTA_TOKEN=1234567890
|
||||
|
||||
direnv allow
|
||||
direnv: loading .envrc
|
||||
direnv: export +ARISTA_TOKEN
|
||||
|
||||
ardl info versions --branch 4.29
|
||||
```
|
59
docs/usage/eos.md
Normal file
59
docs/usage/eos.md
Normal file
|
@ -0,0 +1,59 @@
|
|||
# Download EOS package from arista website
|
||||
|
||||
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
|
||||
|
||||
```bash
|
||||
# Get latest version of EOS using docker format.
|
||||
ardl get eos --latest --format cEOS
|
||||
|
||||
# Get latest version of maintenance type in specific branch 4.29
|
||||
ardl get eos --branch 4.29 --format cEOS --release-type M
|
||||
|
||||
# Get a specific version
|
||||
ardl get eos --version 4.29.4M
|
||||
|
||||
# Get a specific version and import to docker
|
||||
# using default arista/ceos:{version}{release_type}
|
||||
ardl get eos --version 4.29.4M --import-docker
|
||||
|
||||
# Get a specific version and import to EVE-NG
|
||||
ardl get eos --version 4.33.0F --eve-ng
|
||||
```
|
||||
|
||||
## ardl get eos options
|
||||
|
||||
Below are all the options available to get EOS package:
|
||||
|
||||
```bash
|
||||
$ ardl get eos --help
|
||||
Usage: ardl get eos [OPTIONS]
|
||||
|
||||
Download EOS image from Arista server.
|
||||
|
||||
Options:
|
||||
--format TEXT Image format [default: vmdk]
|
||||
--output PATH Path to save image [env var: ARISTA_GET_EOS_OUTPUT;
|
||||
default: .]
|
||||
--latest Get latest version. If --branch is not use, get the
|
||||
latest branch with specific release type [env var:
|
||||
ARISTA_GET_EOS_LATEST]
|
||||
--eve-ng Run EVE-NG vEOS provisioning (only if CLI runs on an
|
||||
EVE-NG server) [env var: ARISTA_GET_EOS_EVE_NG]
|
||||
--import-docker Import docker image to local docker [env var:
|
||||
ARISTA_GET_EOS_IMPORT_DOCKER]
|
||||
--skip-download Skip download process - for debug only
|
||||
--docker-name TEXT Docker image name [env var:
|
||||
ARISTA_GET_EOS_DOCKER_NAME; default: arista/ceos]
|
||||
--docker-tag TEXT Docker image tag [env var: ARISTA_GET_EOS_DOCKER_TAG]
|
||||
--version TEXT EOS version to download [env var:
|
||||
ARISTA_GET_EOS_VERSION]
|
||||
--release-type TEXT Release type (M for Maintenance, F for Feature) [env
|
||||
var: ARISTA_GET_EOS_RELEASE_TYPE; default: F]
|
||||
--branch TEXT Branch to download [env var: ARISTA_GET_EOS_BRANCH]
|
||||
--dry-run Enable dry-run mode: only run code without system
|
||||
changes
|
||||
--help Show this message and exit.
|
||||
```
|
||||
|
||||
!!! info
|
||||
You can get information about available version using the [`ardl info version` cli](./info.md)
|
89
docs/usage/info.md
Normal file
89
docs/usage/info.md
Normal file
|
@ -0,0 +1,89 @@
|
|||
# Get information about softwares versions
|
||||
|
||||
`ardl` comes with a tool to get version information from Arista website. It is valid for both __CloudVision__ and __EOS__ packages.
|
||||
|
||||
## Get information about available versions
|
||||
|
||||
```bash
|
||||
ardl info versions --help
|
||||
Usage: ardl info versions [OPTIONS]
|
||||
|
||||
List available versions of Arista packages (eos or CVP) packages
|
||||
|
||||
Options:
|
||||
--format [json|text|fancy] Output format
|
||||
--package [eos|cvp]
|
||||
-b, --branch TEXT
|
||||
--release-type TEXT
|
||||
--help Show this message and exit.
|
||||
```
|
||||
|
||||
## Usage example
|
||||
|
||||
With this CLI, you can specify either a branch or a release type when applicable to filter information:
|
||||
|
||||
### Fancy format (default)
|
||||
|
||||
```bash
|
||||
# Get F version in branch 4.29 using default fancy mode
|
||||
ardl info versions --branch 4.29 --release-type F
|
||||
|
||||
╭──────────────────────────── Available versions ──────────────────────────────╮
|
||||
│ │
|
||||
│ - version: 4.29.2F │
|
||||
│ - version: 4.29.1F │
|
||||
│ - version: 4.29.0.2F │
|
||||
│ - version: 4.29.2F │
|
||||
│ - version: 4.29.1F │
|
||||
│ - version: 4.29.0.2F │
|
||||
│ │
|
||||
╰──────────────────────────────────────────────────────────────────────────────╯
|
||||
```
|
||||
|
||||
### Text Format
|
||||
|
||||
```bash
|
||||
# Get M version in branch 4.29 using text output
|
||||
❯ ardl info versions --branch 4.29 --release-type M --format text
|
||||
Listing versions
|
||||
- version: 4.29.10M
|
||||
- version: 4.29.9.1M
|
||||
- version: 4.29.9M
|
||||
- version: 4.29.8M
|
||||
- version: 4.29.7.1M
|
||||
...
|
||||
```
|
||||
|
||||
### JSON format
|
||||
|
||||
You can also specify JSON as output format:
|
||||
|
||||
```bash
|
||||
ardl info versions --branch 4.29 --release-type F --format json
|
||||
[
|
||||
{
|
||||
"version": "4.29.2F",
|
||||
"branch": "4.29"
|
||||
},
|
||||
{
|
||||
"version": "4.29.1F",
|
||||
"branch": "4.29"
|
||||
},
|
||||
{
|
||||
"version": "4.29.0.2F",
|
||||
"branch": "4.29"
|
||||
},
|
||||
{
|
||||
"version": "4.29.2F",
|
||||
"branch": "4.29"
|
||||
},
|
||||
{
|
||||
"version": "4.29.1F",
|
||||
"branch": "4.29"
|
||||
},
|
||||
{
|
||||
"version": "4.29.0.2F",
|
||||
"branch": "4.29"
|
||||
}
|
||||
]
|
||||
```
|
77
docs/usage/mapping.md
Normal file
77
docs/usage/mapping.md
Normal file
|
@ -0,0 +1,77 @@
|
|||
# Get information about software mapping
|
||||
|
||||
`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.
|
||||
|
||||
## Get information about available versions
|
||||
|
||||
```bash
|
||||
$ ardl info mapping --help
|
||||
Usage: ardl info mapping [OPTIONS]
|
||||
|
||||
List available flavors of Arista packages (eos or CVP) packages.
|
||||
|
||||
Options:
|
||||
--package [eos|cvp]
|
||||
--format [json|text|fancy] Output format
|
||||
--details Show details for each flavor
|
||||
--help Show this message and exit.
|
||||
```
|
||||
|
||||
## Usage example
|
||||
|
||||
With this CLI, you can specify either a branch or a release type when applicable to filter information:
|
||||
|
||||
|
||||
```bash
|
||||
# Get list of supported packages for EOS.
|
||||
$ ardl info mapping --package eos
|
||||
Log Level is: error
|
||||
|
||||
╭─────────────────────────── Flavors ───────────────╮
|
||||
│ │
|
||||
│ * Flavor: 64 │
|
||||
│ * Flavor: INT │
|
||||
│ * Flavor: 2GB-INT │
|
||||
│ * Flavor: cEOS │
|
||||
│ * Flavor: cEOS64 │
|
||||
│ * Flavor: vEOS │
|
||||
│ * Flavor: vEOS-lab │
|
||||
│ * Flavor: EOS-2GB │
|
||||
│ * Flavor: RN │
|
||||
│ * Flavor: SOURCE │
|
||||
│ * Flavor: default │
|
||||
│ │
|
||||
╰───────────────────────────────────────────────────╯
|
||||
|
||||
# Get list of supported packages for EOS with filename information
|
||||
$ ardl info mapping --package eos
|
||||
Log Level is: error
|
||||
|
||||
╭─────────────────────────────────────────────────── Flavors ─────────╮
|
||||
│ │
|
||||
│ * Flavor: 64 │
|
||||
│ - Information: extension='.swi' prepend='EOS64' │
|
||||
│ * Flavor: INT │
|
||||
│ - Information: extension='-INT.swi' prepend='EOS' │
|
||||
│ * Flavor: 2GB-INT │
|
||||
│ - Information: extension='-INT.swi' prepend='EOS-2GB' │
|
||||
│ * Flavor: cEOS │
|
||||
│ - Information: extension='.tar.xz' prepend='cEOS-lab' │
|
||||
│ * Flavor: cEOS64 │
|
||||
│ - Information: extension='.tar.xz' prepend='cEOS64-lab' │
|
||||
│ * Flavor: vEOS │
|
||||
│ - Information: extension='.vmdk' prepend='vEOS' │
|
||||
│ * Flavor: vEOS-lab │
|
||||
│ - Information: extension='.vmdk' prepend='vEOS-lab' │
|
||||
│ * Flavor: EOS-2GB │
|
||||
│ - Information: extension='.swi' prepend='EOS-2GB' │
|
||||
│ * Flavor: RN │
|
||||
│ - Information: extension='-' prepend='RN' │
|
||||
│ * Flavor: SOURCE │
|
||||
│ - Information: extension='-source.tar' prepend='EOS' │
|
||||
│ * Flavor: default │
|
||||
│ - Information: extension='.swi' prepend='EOS' │
|
||||
│ │
|
||||
╰─────────────────────────────────────────────────────────────────────╯
|
||||
|
||||
```
|
38
docs/usage/path.md
Normal file
38
docs/usage/path.md
Normal file
|
@ -0,0 +1,38 @@
|
|||
# Download any arista package
|
||||
|
||||
This command gives an option for advanced users to download any packages available on arista website and using the standard authentication mechanism.
|
||||
|
||||
!!! warning
|
||||
This command is for advanced user only
|
||||
|
||||
```bash
|
||||
# Get a package from arista server
|
||||
ardl get path -s "/support/path/to/docker/image/cEOS-lab-4.32.3M.tar.xz"
|
||||
|
||||
# Get a package from arista server and import into your docker engine
|
||||
ardl get path -s "/support/path/to/docker/image/cEOS-lab-4.32.3M.tar.xz" --import-docker
|
||||
|
||||
# Get a package from arista server and import into your docker engine with specific image and version
|
||||
ardl get path -s "/support/path/to/docker/image/cEOS-lab-4.32.3M.tar.xz" --import-docker --docker-image arista/myceos --docker-version 4.32.3M
|
||||
```
|
||||
|
||||
## ardl get path options
|
||||
|
||||
```bash
|
||||
$ ardl get path --help
|
||||
Usage: ardl get path [OPTIONS]
|
||||
|
||||
Download image from Arista server using direct path.
|
||||
|
||||
Options:
|
||||
-s, --source TEXT Image path to download from Arista Website
|
||||
-o, --output PATH Path to save downloaded package [env var:
|
||||
ARISTA_GET_PATH_OUTPUT; default: .]
|
||||
--import-docker Import docker image to local docker [env var:
|
||||
ARISTA_GET_PATH_IMPORT_DOCKER]
|
||||
--docker-name TEXT Docker image name [env var:
|
||||
ARISTA_GET_PATH_DOCKER_NAME; default: arista/ceos:raw]
|
||||
--docker-tag TEXT Docker image tag [env var: ARISTA_GET_PATH_DOCKER_TAG;
|
||||
default: dev]
|
||||
--help Show this message and exit.
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue