From ae016fb41e29d2ca01a72c23c51872cb56618e2f Mon Sep 17 00:00:00 2001 From: Thomas Grimonet Date: Tue, 13 Apr 2021 10:13:09 +0200 Subject: [PATCH] doc: update after avd:v2 and cvp:v2.1.2 releases --- .github/workflows/code-execution.yml | 14 +++----------- .gitignore | 10 ++-------- INSTALLATION.md | 10 ++++++++++ Makefile | 15 ++++++++++----- README.md | 9 +++++---- ansible.cfg | 2 +- requirements.txt | 16 ++++++++-------- 7 files changed, 39 insertions(+), 37 deletions(-) diff --git a/.github/workflows/code-execution.yml b/.github/workflows/code-execution.yml index 904e769af..3ac1004ee 100644 --- a/.github/workflows/code-execution.yml +++ b/.github/workflows/code-execution.yml @@ -8,7 +8,9 @@ jobs: steps: - uses: actions/checkout@master - name: 'Install collections' - run: make install + run: | + pip install -r requirements.txt + make install - name: 'Check ansible syntax' run: | ansible-playbook playbooks/dc1-fabric-deploy-cvp.yml --syntax-check @@ -20,13 +22,3 @@ jobs: - name: 'Build AVD & CVP content' run: | ansible-playbook playbooks/dc1-fabric-deploy-cvp.yml --tags build - - name: 'Save Python libs version' - run: | - pip3 freeze - pip3 freeze > inventory/intended/pip-version.txt - - name: 'Remove collections' - run: make uninstall - - uses: actions/upload-artifact@v1 - with: - name: intended-files - path: inventory/ diff --git a/.gitignore b/.gitignore index ef1ba1a1f..4e7282bc6 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,3 @@ -.vscode/* -!.vscode/settings.json -!.vscode/tasks.json -!.vscode/launch.json -!.vscode/extensions.json -*.code-workspace - *.retry -ansible-* \ No newline at end of file +ansible-* +.vscode \ No newline at end of file diff --git a/INSTALLATION.md b/INSTALLATION.md index 567fac1a7..ec7f17fdc 100644 --- a/INSTALLATION.md +++ b/INSTALLATION.md @@ -65,10 +65,20 @@ $ git clone git clone https://github.com/arista-netdevops-community/ansible-avd- $ cd ansible-avd-cloudvision-demo # Run demo shell using docker +# Makefile approach $ make shell +# Manual installation +$ docker pull avdteam/base:3.6 +$ docker run --rm -it \ + -v ./:/projects \ + -v /etc/hosts:/etc/hosts avdteam/base:3.6 # Install required ansible collections +# Makefile approach $ make install +# Manual installation +$ ansible-galaxy collection install arista.avd:==2.0.0 +$ ansible-galaxy collection install arista.cvp:==2.1.2 ``` ## Configure DHCP server on CloudVision diff --git a/Makefile b/Makefile index e6b3aa688..4157c20b8 100644 --- a/Makefile +++ b/Makefile @@ -2,8 +2,8 @@ CONTAINER ?= avdteam/base:3.6 VSCODE_CONTAINER ?= avdteam/vscode:latest VSCODE_PORT ?= 8080 HOME_DIR = $(shell pwd) -AVD_COLLECTION_VERSION ?= v1.1.2 -CVP_COLLECTION_VERSION ?= v2.1.1 +AVD_COLLECTION_VERSION ?= 2.0.0 +CVP_COLLECTION_VERSION ?= 2.1.2 help: ## Display help message @grep -E '^[0-9a-zA-Z_-]+\.*[0-9a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' @@ -36,11 +36,16 @@ ztp: ## Configure ZTP server configlet-upload: ## Upload configlets available in configlets/ to CVP. ansible-playbook playbooks/dc1-upload-configlets.yml +.PHONY: install-git +install-git: ## Install Ansible collections from git + git clone --depth 1 --branch v$(AVD_COLLECTION_VERSION) https://github.com/aristanetworks/ansible-avd.git + git clone --depth 1 --branch v$(CVP_COLLECTION_VERSION) https://github.com/aristanetworks/ansible-cvp.git + pip3 install -r ansible-avd/development/requirements.txt + .PHONY: install install: ## Install Ansible collections - git clone --depth 1 --branch $(AVD_COLLECTION_VERSION) https://github.com/aristanetworks/ansible-avd.git - git clone --depth 1 --branch $(CVP_COLLECTION_VERSION) https://github.com/aristanetworks/ansible-cvp.git - pip3 install -r ansible-avd/development/requirements.txt + ansible-galaxy collection install arista.avd:==${AVD_COLLECTION_VERSION} + ansible-galaxy collection install arista.cvp:==${CVP_COLLECTION_VERSION} .PHONY: uninstall uninstall: ## Remove collection from ansible diff --git a/README.md b/README.md index 32013efce..2b3076caf 100644 --- a/README.md +++ b/README.md @@ -9,13 +9,13 @@ It helps to demonstrate how to bring up an Arista EVPN/VXLAN Fabric from the fir ![Lab Topology](data/cloudvision-device-topology.png) -> Lab is based on GNS3 topology and a CloudVision server running on a VMware instance. +> Lab is based on EVE-NG topology and a CloudVision server running on a VMware instance. A complete guide to setup Arista EOS devices on EVE is available on [AVD website](https://avd.sh/en/latest/docs/how-to/lab-with-nat/) ## Getting Started For detailed setup and demo, please refer to [resources](#resources) below. -> It is recommended to use [docker image](https://hub.docker.com/repository/docker/avdteam/base) with all [arista.cvp](https://github.com/aristanetworks/ansible-cvp) and [arista.avd](https://github.com/aristanetworks/ansible-avd) requirements. It is done with `make shell` command +> It is recommended to use [docker image](https://hub.docker.com/repository/docker/avdteam/base) with all [arista.cvp](https://github.com/aristanetworks/ansible-cvp) and [arista.avd](https://github.com/aristanetworks/ansible-avd) [requirements](https://avd.sh/en/latest/docs/installation/requirements/). It is done with `make shell` command. ```shell # Clone repository @@ -24,11 +24,12 @@ $ git clone https://github.com/arista-netdevops-community/ansible-avd-cloudvisio # Move to folder $ cd ansible-avd-cloudvision-demo -# Run demo shell using docker +# Run demo shell using docker (optional) $ make shell # Install required ansible collections -$ make install +$ ansible-galaxy collection install arista.avd:==2.0.0 +$ ansible-galaxy collection install arista.cvp:==2.1.2 # Edit Inventory information & Authentication information $ vim inventory/inventory.yml diff --git a/ansible.cfg b/ansible.cfg index f31b03fdf..c520e858b 100644 --- a/ansible.cfg +++ b/ansible.cfg @@ -6,7 +6,7 @@ retry_files_enabled = False filter_plugins = ansible-avd/plugins/filters roles_path = ansible-avd/roles library = ansible-avd/library -collections_paths = ./ansible-cvp:./ansible-avd:../ansible-cvp:../ansible-avd:~/.ansible/collections:/usr/share/ansible/collections +collections_paths = ~/.ansible/collections:./ansible-cvp:./ansible-avd:../ansible-cvp:../ansible-avd:/usr/share/ansible/collections action_plugins = /usr/lib/python2.7/site-packages/napalm_ansible/plugins/action jinja2_extensions = jinja2.ext.loopcontrols,jinja2.ext.do,jinja2.ext.i18n # enable the YAML callback plugin. diff --git a/requirements.txt b/requirements.txt index aeb7cd5c7..384e1e82a 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,10 +1,10 @@ -ansible==2.9.6 +ansible==2.10.0 netaddr==0.7.19 -Jinja2==2.10.3 -requests==2.22.0 +Jinja2==2.11.3 treelib==1.5.5 -pytest==5.4.2 -pytest-html==2.1.1 -ward==0.46.0b0 -git+https://github.com/batfish/pybatfish.git -paramiko \ No newline at end of file +cvprac==1.0.5 +paramiko==2.7.1 +jsonschema==3.2.0 +requests==2.25.1 +PyYAML==5.4.1 +md-toc==7.1.0 \ No newline at end of file