Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Azure/sonic-utilities int…
Browse files Browse the repository at this point in the history
…o feature/add-lacp-rate-to-portchannel
  • Loading branch information
Myron Sosyak committed Mar 17, 2022
2 parents 5199ab4 + 1cf1d03 commit 34549bb
Show file tree
Hide file tree
Showing 28 changed files with 2,368 additions and 445 deletions.
65 changes: 0 additions & 65 deletions .azure-pipelines/build-docker-sonic-vs-template.yml

This file was deleted.

92 changes: 0 additions & 92 deletions .azure-pipelines/test-docker-sonic-vs-template.yml

This file was deleted.

28 changes: 10 additions & 18 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,22 @@ stages:
image: sonicdev-microsoft.azurecr.io:443/sonic-slave-buster:latest

steps:
- script: |
sourceBranch=$(Build.SourceBranchName)
if [[ "$(Build.Reason)" == "PullRequest" ]];then
sourceBranch=$(System.PullRequest.TargetBranch)
fi
echo "Download artifact branch: $sourceBranch"
echo "##vso[task.setvariable variable=sourceBranch]$sourceBranch"
displayName: "Get correct artifact downloading branch"
- task: DownloadPipelineArtifact@2
inputs:
source: specific
project: build
pipeline: 1
pipeline: 142
artifact: sonic-buildimage.vs
runVersion: 'latestFromBranch'
runBranch: 'refs/heads/master'
runBranch: 'refs/heads/$(sourceBranch)'
displayName: "Download artifacts from latest sonic-buildimage build"

- script: |
Expand Down Expand Up @@ -117,19 +125,3 @@ stages:
- publish: '$(System.DefaultWorkingDirectory)/dist/'
artifact: wheels
displayName: "Publish Python wheels"

- stage: BuildDocker
dependsOn: Build
condition: succeeded('Build')
jobs:
- template: .azure-pipelines/build-docker-sonic-vs-template.yml
parameters:
artifact_name: docker-sonic-vs

- stage: Test
dependsOn: BuildDocker
condition: succeeded('BuildDocker')
jobs:
- template: .azure-pipelines/test-docker-sonic-vs-template.yml
parameters:
log_artifact_name: log
8 changes: 4 additions & 4 deletions config/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1796,11 +1796,11 @@ def add_portchannel_member(ctx, portchannel_name, port_name):
ctx.fail("{} is not present.".format(portchannel_name))

# Dont allow a port to be member of port channel if it is configured with an IP address
for key in db.get_table('INTERFACE').keys():
if type(key) != tuple:
for key,value in db.get_table('INTERFACE').items():
if type(key) == tuple:
continue
if key[0] == port_name:
ctx.fail(" {} has ip address {} configured".format(port_name, key[1]))
if key == port_name:
ctx.fail(" {} has ip address configured".format(port_name))
return

# Dont allow a port to be member of port channel if it is configured as a VLAN member
Expand Down
Loading

0 comments on commit 34549bb

Please sign in to comment.