Skip to content

Commit

Permalink
Merge pull request #425 from titom73/issues/407
Browse files Browse the repository at this point in the history
Add support for unprovisioned device in CV deployment
  • Loading branch information
carlbuchmann authored Dec 17, 2020
2 parents 7c14fff + fb4404d commit fb25ade
Show file tree
Hide file tree
Showing 75 changed files with 25,922 additions and 101 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/molecule-cvp-deployment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Ansible Molecule for CV Configuration build
on:
push:
branches:
- devel
pull_request:
paths:
- 'ansible_collections/arista/avd/roles/eos_config_deploy_cvp/tasks/**'
- 'ansible_collections/arista/avd/roles/eos_config_deploy_cvp/templates/**'
- 'ansible_collections/arista/avd/molecules/eos_config_deploy_cvp/**'
- 'development/requirements**'
- '.github/workflows/molecule-cvp-deployment.yml'
# - '.github/git-repo-state-monitor.sh'
jobs:
molecule:
name: Run CI test for eos_config_deploy_cvp
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
avd_scenario:
- 'eos_config_deploy_cvp'
steps:
- name: 'set environment variables'
run: |
echo "PY_COLORS=1" >> $GITHUB_ENV
echo "ANSIBLE_FORCE_COLOR=1" >> $GITHUB_ENV
- uses: actions/checkout@v1
- name: Set up Python 3
uses: actions/setup-python@v2.1.4
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r development/requirements.txt
pip install -r development/requirements-dev.txt
- name: Execute molecule
run: |
cd ansible_collections/arista/avd
molecule test --destroy=never --scenario-name ${{ matrix.avd_scenario }}
ls -alR molecule
# - name: Monitor git status
# run: |
# bash .github/git-repo-state-monitor.sh

- uses: actions/upload-artifact@v1
with:
name: molecule-results-${{ matrix.avd_scenario }}
path: ansible_collections/arista/avd/molecule/${{ matrix.avd_scenario }}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -120,3 +120,6 @@ ansible_collections/arista/avd/docs/*.rst

# Molecule AVD build folders
ansible_collections/arista/avd/molecule/*/config_backup

# Ansible test folder
ansible_collections/arista/avd/tests/
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
- name: Configure local folders
hosts: DC1_FABRIC
gather_facts: false
connection: local
vars:
root_dir: '{{playbook_dir}}'
tasks:
- name: generate intented variables
import_role:
name: arista.avd.eos_l3ls_evpn
- name: generate device intended config and documention
import_role:
name: arista.avd.eos_cli_config_gen

- name: Converge
hosts: cv_server
gather_facts: false
connection: local
vars:
root_dir: '{{playbook_dir}}'
tasks:
- name: run CVP provisioning
tags: generate
import_role:
name: arista.avd.eos_config_deploy_cvp
vars:
container_root: 'DC1_FABRIC'
configlets_prefix: 'AVD'
device_filter: 'DC1'
execute_tasks: false
state: present
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
- name: Configure local folders
hosts: DC1_FABRIC
gather_facts: false
connection: local
vars:
root_dir: '{{playbook_dir}}'
tasks:
- name: create local output folders
delegate_to: 127.0.0.1
import_role:
name: arista.avd.build_output_folders
run_once: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
- name: Remove output folders
hosts: all
gather_facts: false
connection: local
tasks:
- name: delete local folders
delegate_to: 127.0.0.1
run_once: true
file:
path: "{{root_dir}}/{{ item }}"
state: absent
with_items:
- documentation
- intended
- config_backup
- reports
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
type, Leaf Node,Leaf Interface,Leaf IP Address,Port-Channel,Peer Node,Peer Interface,Peer IP Address,Port-Channel
L3 Leaf,DC1-BL1A,Ethernet1,172.31.255.41/31,N/A,DC1-SPINE1,Ethernet6,172.31.255.40/31,N/A
L3 Leaf,DC1-BL1A,Ethernet2,172.31.255.43/31,N/A,DC1-SPINE2,Ethernet6,172.31.255.42/31,N/A
L3 Leaf,DC1-BL1A,Ethernet3,172.31.255.45/31,N/A,DC1-SPINE3,Ethernet6,172.31.255.44/31,N/A
L3 Leaf,DC1-BL1A,Ethernet4,172.31.255.47/31,N/A,DC1-SPINE4,Ethernet6,172.31.255.46/31,N/A
L3 Leaf,DC1-BL1B,Ethernet1,172.31.255.49/31,N/A,DC1-SPINE1,Ethernet7,172.31.255.48/31,N/A
L3 Leaf,DC1-BL1B,Ethernet2,172.31.255.51/31,N/A,DC1-SPINE2,Ethernet7,172.31.255.50/31,N/A
L3 Leaf,DC1-BL1B,Ethernet3,172.31.255.53/31,N/A,DC1-SPINE3,Ethernet7,172.31.255.52/31,N/A
L3 Leaf,DC1-BL1B,Ethernet4,172.31.255.55/31,N/A,DC1-SPINE4,Ethernet7,172.31.255.54/31,N/A
L3 Leaf,DC1-LEAF1A,Ethernet1,172.31.255.1/31,N/A,DC1-SPINE1,Ethernet1,172.31.255.0/31,N/A
L3 Leaf,DC1-LEAF1A,Ethernet2,172.31.255.3/31,N/A,DC1-SPINE2,Ethernet1,172.31.255.2/31,N/A
L3 Leaf,DC1-LEAF1A,Ethernet3,172.31.255.5/31,N/A,DC1-SPINE3,Ethernet1,172.31.255.4/31,N/A
L3 Leaf,DC1-LEAF1A,Ethernet4,172.31.255.7/31,N/A,DC1-SPINE4,Ethernet1,172.31.255.6/31,N/A
L3 Leaf,DC1-LEAF2A,Ethernet1,172.31.255.9/31,N/A,DC1-SPINE1,Ethernet2,172.31.255.8/31,N/A
L3 Leaf,DC1-LEAF2A,Ethernet2,172.31.255.11/31,N/A,DC1-SPINE2,Ethernet2,172.31.255.10/31,N/A
L3 Leaf,DC1-LEAF2A,Ethernet3,172.31.255.13/31,N/A,DC1-SPINE3,Ethernet2,172.31.255.12/31,N/A
L3 Leaf,DC1-LEAF2A,Ethernet4,172.31.255.15/31,N/A,DC1-SPINE4,Ethernet2,172.31.255.14/31,N/A
L3 Leaf,DC1-LEAF2B,Ethernet1,172.31.255.17/31,N/A,DC1-SPINE1,Ethernet3,172.31.255.16/31,N/A
L3 Leaf,DC1-LEAF2B,Ethernet2,172.31.255.19/31,N/A,DC1-SPINE2,Ethernet3,172.31.255.18/31,N/A
L3 Leaf,DC1-LEAF2B,Ethernet3,172.31.255.21/31,N/A,DC1-SPINE3,Ethernet3,172.31.255.20/31,N/A
L3 Leaf,DC1-LEAF2B,Ethernet4,172.31.255.23/31,N/A,DC1-SPINE4,Ethernet3,172.31.255.22/31,N/A
L3 Leaf,DC1-SVC3A,Ethernet1,172.31.255.25/31,N/A,DC1-SPINE1,Ethernet4,172.31.255.24/31,N/A
L3 Leaf,DC1-SVC3A,Ethernet2,172.31.255.27/31,N/A,DC1-SPINE2,Ethernet4,172.31.255.26/31,N/A
L3 Leaf,DC1-SVC3A,Ethernet3,172.31.255.29/31,N/A,DC1-SPINE3,Ethernet4,172.31.255.28/31,N/A
L3 Leaf,DC1-SVC3A,Ethernet4,172.31.255.31/31,N/A,DC1-SPINE4,Ethernet4,172.31.255.30/31,N/A
L3 Leaf,DC1-SVC3B,Ethernet1,172.31.255.33/31,N/A,DC1-SPINE1,Ethernet5,172.31.255.32/31,N/A
L3 Leaf,DC1-SVC3B,Ethernet2,172.31.255.35/31,N/A,DC1-SPINE2,Ethernet5,172.31.255.34/31,N/A
L3 Leaf,DC1-SVC3B,Ethernet3,172.31.255.37/31,N/A,DC1-SPINE3,Ethernet5,172.31.255.36/31,N/A
L3 Leaf,DC1-SVC3B,Ethernet4,172.31.255.39/31,N/A,DC1-SPINE4,Ethernet5,172.31.255.38/31,N/A
L2 Leaf,DC1-L2LEAF1A,Ethernet1,N/A,Po1,DC1-LEAF2A,Ethernet7,N/A,Po7
L2 Leaf,DC1-L2LEAF1A,Ethernet2,N/A,Po1,DC1-LEAF2B,Ethernet7,N/A,Po7
L2 Leaf,DC1-L2LEAF2A,Ethernet1,N/A,Po1,DC1-SVC3A,Ethernet7,N/A,Po7
L2 Leaf,DC1-L2LEAF2A,Ethernet2,N/A,Po1,DC1-SVC3B,Ethernet7,N/A,Po7
L2 Leaf,DC1-L2LEAF2B,Ethernet1,N/A,Po1,DC1-SVC3A,Ethernet8,N/A,Po8
L2 Leaf,DC1-L2LEAF2B,Ethernet2,N/A,Po1,DC1-SVC3B,Ethernet8,N/A,Po8
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
Node Type,Node,Node Interface,Peer Type,Peer,Peer Interface
spine,DC1-SPINE1,Ethernet1,l3leaf,DC1-LEAF1A,Ethernet1
spine,DC1-SPINE1,Ethernet2,l3leaf,DC1-LEAF2A,Ethernet1
spine,DC1-SPINE1,Ethernet3,l3leaf,DC1-LEAF2B,Ethernet1
spine,DC1-SPINE1,Ethernet4,l3leaf,DC1-SVC3A,Ethernet1
spine,DC1-SPINE1,Ethernet5,l3leaf,DC1-SVC3B,Ethernet1
spine,DC1-SPINE1,Ethernet6,l3leaf,DC1-BL1A,Ethernet1
spine,DC1-SPINE1,Ethernet7,l3leaf,DC1-BL1B,Ethernet1
spine,DC1-SPINE2,Ethernet1,l3leaf,DC1-LEAF1A,Ethernet2
spine,DC1-SPINE2,Ethernet2,l3leaf,DC1-LEAF2A,Ethernet2
spine,DC1-SPINE2,Ethernet3,l3leaf,DC1-LEAF2B,Ethernet2
spine,DC1-SPINE2,Ethernet4,l3leaf,DC1-SVC3A,Ethernet2
spine,DC1-SPINE2,Ethernet5,l3leaf,DC1-SVC3B,Ethernet2
spine,DC1-SPINE2,Ethernet6,l3leaf,DC1-BL1A,Ethernet2
spine,DC1-SPINE2,Ethernet7,l3leaf,DC1-BL1B,Ethernet2
spine,DC1-SPINE3,Ethernet1,l3leaf,DC1-LEAF1A,Ethernet3
spine,DC1-SPINE3,Ethernet2,l3leaf,DC1-LEAF2A,Ethernet3
spine,DC1-SPINE3,Ethernet3,l3leaf,DC1-LEAF2B,Ethernet3
spine,DC1-SPINE3,Ethernet4,l3leaf,DC1-SVC3A,Ethernet3
spine,DC1-SPINE3,Ethernet5,l3leaf,DC1-SVC3B,Ethernet3
spine,DC1-SPINE3,Ethernet6,l3leaf,DC1-BL1A,Ethernet3
spine,DC1-SPINE3,Ethernet7,l3leaf,DC1-BL1B,Ethernet3
spine,DC1-SPINE4,Ethernet1,l3leaf,DC1-LEAF1A,Ethernet4
spine,DC1-SPINE4,Ethernet2,l3leaf,DC1-LEAF2A,Ethernet4
spine,DC1-SPINE4,Ethernet3,l3leaf,DC1-LEAF2B,Ethernet4
spine,DC1-SPINE4,Ethernet4,l3leaf,DC1-SVC3A,Ethernet4
spine,DC1-SPINE4,Ethernet5,l3leaf,DC1-SVC3B,Ethernet4
spine,DC1-SPINE4,Ethernet6,l3leaf,DC1-BL1A,Ethernet4
spine,DC1-SPINE4,Ethernet7,l3leaf,DC1-BL1B,Ethernet4
l3leaf,DC1-BL1A,Ethernet1,spine,DC1-SPINE1,Ethernet6
l3leaf,DC1-BL1A,Ethernet2,spine,DC1-SPINE2,Ethernet6
l3leaf,DC1-BL1A,Ethernet3,spine,DC1-SPINE3,Ethernet6
l3leaf,DC1-BL1A,Ethernet4,spine,DC1-SPINE4,Ethernet6
l3leaf,DC1-BL1A,Ethernet5,mlag_peer,DC1-BL1B,Ethernet5
l3leaf,DC1-BL1A,Ethernet6,mlag_peer,DC1-BL1B,Ethernet6
l3leaf,DC1-BL1B,Ethernet1,spine,DC1-SPINE1,Ethernet7
l3leaf,DC1-BL1B,Ethernet2,spine,DC1-SPINE2,Ethernet7
l3leaf,DC1-BL1B,Ethernet3,spine,DC1-SPINE3,Ethernet7
l3leaf,DC1-BL1B,Ethernet4,spine,DC1-SPINE4,Ethernet7
l3leaf,DC1-BL1B,Ethernet5,mlag_peer,DC1-BL1A,Ethernet5
l3leaf,DC1-BL1B,Ethernet6,mlag_peer,DC1-BL1A,Ethernet6
l3leaf,DC1-LEAF1A,Ethernet1,spine,DC1-SPINE1,Ethernet1
l3leaf,DC1-LEAF1A,Ethernet2,spine,DC1-SPINE2,Ethernet1
l3leaf,DC1-LEAF1A,Ethernet3,spine,DC1-SPINE3,Ethernet1
l3leaf,DC1-LEAF1A,Ethernet4,spine,DC1-SPINE4,Ethernet1
l3leaf,DC1-LEAF1A,Ethernet6,server,server02_SINGLE_NODE_TRUNK,Eth1
l3leaf,DC1-LEAF1A,Ethernet7,server,server02_SINGLE_NODE,Eth1
l3leaf,DC1-LEAF2A,Ethernet1,spine,DC1-SPINE1,Ethernet2
l3leaf,DC1-LEAF2A,Ethernet2,spine,DC1-SPINE2,Ethernet2
l3leaf,DC1-LEAF2A,Ethernet3,spine,DC1-SPINE3,Ethernet2
l3leaf,DC1-LEAF2A,Ethernet4,spine,DC1-SPINE4,Ethernet2
l3leaf,DC1-LEAF2A,Ethernet5,mlag_peer,DC1-LEAF2B,Ethernet5
l3leaf,DC1-LEAF2A,Ethernet6,mlag_peer,DC1-LEAF2B,Ethernet6
l3leaf,DC1-LEAF2A,Ethernet7,l2leaf,DC1-L2LEAF1A,Ethernet1
l3leaf,DC1-LEAF2A,Ethernet10,server,server01_MLAG,Eth2
l3leaf,DC1-LEAF2B,Ethernet1,spine,DC1-SPINE1,Ethernet3
l3leaf,DC1-LEAF2B,Ethernet2,spine,DC1-SPINE2,Ethernet3
l3leaf,DC1-LEAF2B,Ethernet3,spine,DC1-SPINE3,Ethernet3
l3leaf,DC1-LEAF2B,Ethernet4,spine,DC1-SPINE4,Ethernet3
l3leaf,DC1-LEAF2B,Ethernet5,mlag_peer,DC1-LEAF2A,Ethernet5
l3leaf,DC1-LEAF2B,Ethernet6,mlag_peer,DC1-LEAF2A,Ethernet6
l3leaf,DC1-LEAF2B,Ethernet7,l2leaf,DC1-L2LEAF1A,Ethernet2
l3leaf,DC1-LEAF2B,Ethernet10,server,server01_MLAG,Eth3
l3leaf,DC1-SVC3A,Ethernet1,spine,DC1-SPINE1,Ethernet4
l3leaf,DC1-SVC3A,Ethernet2,spine,DC1-SPINE2,Ethernet4
l3leaf,DC1-SVC3A,Ethernet3,spine,DC1-SPINE3,Ethernet4
l3leaf,DC1-SVC3A,Ethernet4,spine,DC1-SPINE4,Ethernet4
l3leaf,DC1-SVC3A,Ethernet5,mlag_peer,DC1-SVC3B,Ethernet5
l3leaf,DC1-SVC3A,Ethernet6,mlag_peer,DC1-SVC3B,Ethernet6
l3leaf,DC1-SVC3A,Ethernet7,l2leaf,DC1-L2LEAF2A,Ethernet1
l3leaf,DC1-SVC3A,Ethernet8,l2leaf,DC1-L2LEAF2B,Ethernet1
l3leaf,DC1-SVC3A,Ethernet10,server,server03_ESI,Eth1
l3leaf,DC1-SVC3B,Ethernet1,spine,DC1-SPINE1,Ethernet5
l3leaf,DC1-SVC3B,Ethernet2,spine,DC1-SPINE2,Ethernet5
l3leaf,DC1-SVC3B,Ethernet3,spine,DC1-SPINE3,Ethernet5
l3leaf,DC1-SVC3B,Ethernet4,spine,DC1-SPINE4,Ethernet5
l3leaf,DC1-SVC3B,Ethernet5,mlag_peer,DC1-SVC3A,Ethernet5
l3leaf,DC1-SVC3B,Ethernet6,mlag_peer,DC1-SVC3A,Ethernet6
l3leaf,DC1-SVC3B,Ethernet7,l2leaf,DC1-L2LEAF2A,Ethernet2
l3leaf,DC1-SVC3B,Ethernet8,l2leaf,DC1-L2LEAF2B,Ethernet2
l2leaf,DC1-L2LEAF1A,Ethernet1,l3leaf,DC1-LEAF2A,Ethernet7
l2leaf,DC1-L2LEAF1A,Ethernet2,l3leaf,DC1-LEAF2B,Ethernet7
l2leaf,DC1-L2LEAF2A,Ethernet1,l3leaf,DC1-SVC3A,Ethernet7
l2leaf,DC1-L2LEAF2A,Ethernet2,l3leaf,DC1-SVC3B,Ethernet7
l2leaf,DC1-L2LEAF2A,Ethernet3,mlag_peer,DC1-L2LEAF2B,Ethernet3
l2leaf,DC1-L2LEAF2A,Ethernet4,mlag_peer,DC1-L2LEAF2B,Ethernet4
l2leaf,DC1-L2LEAF2B,Ethernet1,l3leaf,DC1-SVC3A,Ethernet8
l2leaf,DC1-L2LEAF2B,Ethernet2,l3leaf,DC1-SVC3B,Ethernet8
l2leaf,DC1-L2LEAF2B,Ethernet3,mlag_peer,DC1-L2LEAF2A,Ethernet3
l2leaf,DC1-L2LEAF2B,Ethernet4,mlag_peer,DC1-L2LEAF2A,Ethernet4
Loading

0 comments on commit fb25ade

Please sign in to comment.