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

Feat(eos_cli_config_gen): Add ptp profiles for ITU-T G8275 support #4230

Merged

Conversation

colinmacgiolla
Copy link
Contributor

@colinmacgiolla colinmacgiolla commented Jul 19, 2024

Change Summary

Add support for settting the ITU-T G.8275.1 and .2 support, as well as allowing the handling of PTP frames on interfaces. See here for details on the feature.

Related Issue(s)

Fixes #

Component(s) name

arista.avd.pyavd.eos_cli_config_gen

Proposed changes

On the PTP level, we are just adding the profile key, which can be set to g8275_1 or g8275_2 profiles.
On the interface level we need to indicate if we should recognise either the forwardable or non-forwardable PTP frames.

I've set the the following model on the port-channel and ethernet interface level:

            profile:
              type: dict
              keys:
                g8275_1:
                  type: dict
                  keys:
                    destination_mac_address:
                      type: str
                      valid_values:
                        - forwardable
                        - non-forwardable

How to test

Updated molecule tests to reflect device config

Checklist

User Checklist

  • N/A

Repository Checklist

  • My code has been rebased from devel before I start
  • I have read the CONTRIBUTING document.
  • My change requires a change to the documentation and documentation have been updated accordingly.
  • I have updated molecule CI testing accordingly. (check the box if not applicable)

Copy link

Review docs on Read the Docs

To test this pull request:

# Create virtual environment for this testing below the current directory
python -m venv test-avd-pr-4230
# Activate the virtual environment
source test-avd-pr-4230/bin/activate
# Install all requirements including PyAVD
pip install "pyavd[ansible] @ git+https://github.com/colinmacgiolla/ansible-avd.git@add_ptp_profiles#subdirectory=python-avd" --force
# Install Ansible collection
ansible-galaxy collection install git+https://github.com/colinmacgiolla/ansible-avd.git#/ansible_collections/arista/avd/,add_ptp_profiles --force
# Optional: Install AVD examples
cd test-avd-pr-4230
ansible-playbook arista.avd.install_examples

@github-actions github-actions bot added role: eos_cli_config_gen issue related to eos_cli_config_gen role state: CI Updated CI scenario have been updated in the PR state: Documentation role Updated labels Jul 19, 2024
@colinmacgiolla colinmacgiolla marked this pull request as ready for review July 19, 2024 11:48
@colinmacgiolla colinmacgiolla requested review from a team as code owners July 19, 2024 11:48
Copy link
Contributor

@ClausHolbechArista ClausHolbechArista left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor data model request but other than that looks good to me.

@ClausHolbechArista ClausHolbechArista added the one approval This PR has one approval and is only missing one more. label Jul 23, 2024
@ClausHolbechArista ClausHolbechArista requested a review from a team July 23, 2024 05:32
@ClausHolbechArista ClausHolbechArista added this to the v4.10.0 milestone Jul 25, 2024
@ClausHolbechArista ClausHolbechArista dismissed their stale review July 25, 2024 08:59

changes needed.

@ClausHolbechArista ClausHolbechArista removed the one approval This PR has one approval and is only missing one more. label Jul 25, 2024
@ClausHolbechArista ClausHolbechArista added the one approval This PR has one approval and is only missing one more. label Jul 25, 2024
@colinmacgiolla
Copy link
Contributor Author

@MaheshGSLAB - I'm not understanding why the negative test is failing on something that has nothing to do with my changes?

@ClausHolbechArista
Copy link
Contributor

@MaheshGSLAB - I'm not understanding why the negative test is failing on something that has nothing to do with my changes?

Fixed now. Something sneaked in from another PR.

Copy link

sonarcloud bot commented Jul 26, 2024

@ClausHolbechArista ClausHolbechArista merged commit 553990f into aristanetworks:devel Jul 26, 2024
44 checks passed
@colinmacgiolla colinmacgiolla deleted the add_ptp_profiles branch July 26, 2024 08:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
one approval This PR has one approval and is only missing one more. rn: Feat(eos_cli_config_gen) role: eos_cli_config_gen issue related to eos_cli_config_gen role state: CI Updated CI scenario have been updated in the PR state: Documentation role Updated
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants