Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: Update readme to point to website documentation #110

Merged
merged 2 commits into from
Dec 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
153 changes: 5 additions & 148 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@
![PyPI - Downloads/month](https://img.shields.io/pypi/dm/eos-downloader)
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)


# Arista Software Downloader

## Overview

A project to download Arista softwares to local folder, Cloudvision or EVE-NG. It comes in 2 way: a framework with object to automate Arista software download and a CLI for human activities.

> [!CAUTION]
Expand All @@ -22,43 +23,9 @@ pip install eos-downloader
ardl --token <your-token> get eos --format 64 --latest --release-type M
```

> [!NOTE]
> 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.

## CLI commands

The CLI comes with a set of options to make life easier:

- Token (`--token`) can be loaded from environment variable: `ARISTA_TOKEN`
- Log level management (`--log-level`). Can be set to any value from `debug` to `critical`
- A switch to enable rich exception management (`--debug-enabled`)

```bash
ardl --help
Usage: ardl [OPTIONS] COMMAND [ARGS]...

Arista Network Download CLI

Options:
--version Show the version and exit.
--token TEXT Arista Token from your customer account
[env var: ARISTA_TOKEN]
--log-level, --log [debug|info|warning|error|critical]
Logging level of the command
--debug-enabled, --debug Activate debug mode for ardl cli
--help Show this message and exit.

Commands:
debug Debug commands to work with ardl
get Download Arista from Arista website
info List information from Arista website
```

> [!WARNING]
> To use this CLI you need to get a valid token from your [Arista Account page](https://www.arista.com/en/users/profile).
> For technical reason, it is only available for customers with active maintenance contracts and not for personnal accounts
Full documentation is available on [our website](https://titom73.github.io/eos-downloader/).

### Download EOS package from arista website
## 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

Expand All @@ -79,120 +46,10 @@ ardl get eos --version 4.29.4M --import-docker
ardl get eos --version 4.33.0F --eve-ng
```

### Get information about softwares versions

`ardl` comes witth a tool to get version information from Arista website.

#### 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.
```

With this CLI, you can specify either a branch or a release type when applicable to filter information:

```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 │
│ │
╰──────────────────────────────────────────────────────────────────────────────╯

# 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
...
```

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"
}
]
```

##### Get information about latest version available

CLI has option to get latest version available. Like `ardl info versions`, you can filter by `branch` and/or `release-type` when applicable.

```bash
ardl info latest --help
Usage: ardl info latest [OPTIONS]

List available versions of Arista packages (eos or CVP) packages

Options:
--format [json|text] Output format
--package [eos|cvp]
-b, --branch TEXT
--release-type TEXT
--log-level, --log [debug|info|warning|error|critical]
Logging level of the command
--help Show this message and exit.
```

## FAQ

On EVE-NG, you may have to install/upgrade __pyOpenSSL__ in version `23.0.0`:

```bash
# Error when running ardl: AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'

$ pip install pyopenssl --upgrade
```

## Author

From an original idea of [@Mark Rayson](https://github.com/Sparky-python) in [arista-netdevops-community/eos-scripts](https://github.com/arista-netdevops-community/eos-scripts)

## License

Code is under [Apache2](LICENSE) License
Code is under [Apache2](https://github.com/titom73/eos-downloader/blob/main/LICENSE) License
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ From an original idea of [@Mark Rayson](https://github.com/Sparky-python) in [ar

## License

Code is under [Apache2](LICENSE) License
Code is under [Apache2](https://github.com/titom73/eos-downloader/blob/main/LICENSE) License
Loading