Skip to content

Conversation

@QxBytes
Copy link
Contributor

@QxBytes QxBytes commented Jul 9, 2025

Reason for Change:

Adds image publishing for azure iptables monitor to ACN Official Build pipeline and ACN PR pipeline
Merge after #3779

Issue Fixed:

Requirements:

Notes:
ACN PR: https://msazure.visualstudio.com/One/_build/results?buildId=129848847&view=results
ACN Build Pipeline: https://dev.azure.com/msazure/One/_build/results?buildId=129816140&view=results
ACN Unofficial Build: https://msazure.visualstudio.com/One/_build/results?buildId=129854515&view=results
which feeds into ACN Buddy Image Release: https://dev.azure.com/msazure/One/_build/results?buildId=129977665&view=results

After rebase:
ACN PR: https://msazure.visualstudio.com/One/_build/results?buildId=132175501&view=results
ACN Unofficial Build: https://msazure.visualstudio.com/One/_build/results?buildId=132175800&view=results

@QxBytes QxBytes self-assigned this Jul 9, 2025
@QxBytes QxBytes added ci Infra or tooling. cilium Related to Cilium. labels Jul 9, 2025
@QxBytes QxBytes requested a review from Copilot July 9, 2025 22:34
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds the Azure iptables monitor component and wires it into the ACN build and release pipelines.

  • Introduces the azure-iptables-monitor module with implementation, tests, and Dockerfile
  • Updates go.mod, Makefile, and CODEOWNERS to include the new component
  • Extends pipeline YAML and build scripts to publish the monitor image

Reviewed Changes

Copilot reviewed 12 out of 13 changed files in this pull request and generated no comments.

Show a summary per file
File Description
azure-iptables-monitor/iptables_monitor.go implement monitoring logic and CLI entrypoint
azure-iptables-monitor/iptables_monitor_test.go add unit tests for rule-matching functions
azure-iptables-monitor/go.mod declare module path and dependencies
azure-iptables-monitor/README.md document usage, pattern files, and flags
azure-iptables-monitor/Dockerfile containerize the monitor binary
Makefile add build/image/archive targets for the new component
.pipelines/run-pipeline.yaml inject AZURE_IPTABLES_MONITOR_VERSION and jobs
.pipelines/pipeline.yaml define monitor platforms and manifest stages
.pipelines/build/scripts/azure-iptables-monitor.sh pipeline build script for the monitor
.pipelines/build/ob-prepare.steps.yaml set output variable for monitor version
.pipelines/build/dockerfiles/azure-iptables-monitor.Dockerfile pipeline Dockerfile for the monitor
.github/CODEOWNERS add code owners for azure-iptables-monitor/
Comments suppressed due to low confidence (2)

.pipelines/run-pipeline.yaml:41

  • The indentation of this line is two spaces less than the surrounding environment variables, which will break the YAML structure. Align it with the other entries.
 AZURE_IPTABLES_MONITOR_VERSION: $[ stageDependencies.setup.env.outputs['EnvironmentalVariables.azureIptablesMonitorVersion'] ] 

azure-iptables-monitor/iptables_monitor.go:95

  • Consider adding unit tests for GetRules to verify chains are listed and rules are aggregated correctly, including error handling paths.
func GetRules(client IPTablesClient, tableName string) ([]string, error) { 
@QxBytes QxBytes force-pushed the alew/add-azure-iptables-monitor-pipeline branch from b472c53 to 0803b3a Compare July 30, 2025 19:29
@QxBytes QxBytes marked this pull request as ready for review July 30, 2025 23:52
@QxBytes QxBytes requested review from a team as code owners July 30, 2025 23:52
@QxBytes QxBytes requested a review from carlotaarvela July 30, 2025 23:52
@QxBytes
Copy link
Contributor Author

QxBytes commented Jul 30, 2025

/azp run Azure Container Networking PR

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).
Copy link
Contributor

@jpayne3506 jpayne3506 left a comment

Choose a reason for hiding this comment

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

Lgtm, any plans to add azure-iptables image to make dockerfiles? Functionally it should make 0 difference as the final stage is distroless + iptables + binary, but it would keep our components base image at parity across the repo

dockerfiles: tools ## Render all Dockerfile templates with current state of world
@make -f build/images.mk render PATH=cns
@make -f build/images.mk render PATH=cni

@QxBytes
Copy link
Contributor Author

QxBytes commented Aug 1, 2025

Lgtm, any plans to add azure-iptables image to make dockerfiles? Functionally it should make 0 difference as the final stage is distroless + iptables + binary, but it would keep our components base image at parity across the repo

dockerfiles: tools ## Render all Dockerfile templates with current state of world
@make -f build/images.mk render PATH=cns
@make -f build/images.mk render PATH=cni

I can look into it but currently not too familiar with the process or the benefits esp if it seems like it'll be the same in the end?
Would this change also apply to other components other than cns and cni, ex: the ip masq merger?

@QxBytes QxBytes added this pull request to the merge queue Aug 2, 2025
Merged via the queue into master with commit 8cc5b7e Aug 2, 2025
114 of 116 checks passed
@QxBytes QxBytes deleted the alew/add-azure-iptables-monitor-pipeline branch August 2, 2025 21:37
NihaNallappagari pushed a commit to NihaNallappagari/azure-container-networking that referenced this pull request Sep 4, 2025
* add azure iptables monitor to pipelines * strip debug symbols from azure iptables monitor
sivakami-projects pushed a commit that referenced this pull request Oct 23, 2025
* add azure iptables monitor to pipelines * strip debug symbols from azure iptables monitor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Infra or tooling. cilium Related to Cilium.

4 participants