Skip to content

docs: Update README with Docker image generation documentation #3723

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

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Jun 6, 2025

Added comprehensive Docker image generation documentation to the main README covering all four core networking components as requested in the issue.

Changes Made

Added a new "Docker Image Generation" section to README.md that includes:

Prerequisites

  • Docker or Podman installation requirements
  • Multi-platform build setup instructions

Component-Specific Build Commands

Documentation for building Docker images for each of the four requested components:

  1. Container Network Service (CNS)
make cns-image
make cns-image-name-and-tag
  1. Container Network Interface (CNI)
make cni-image
make cni-image-name-and-tag
  1. Network Policy Manager (NPM)
make npm-image
make npm-image-name-and-tag
  1. Azure IP Address Management (Azure-IPAM)
make azure-ipam-image
make azure-ipam-image-name-and-tag

Advanced Features

  • Customization options: Platform targeting, custom registries, container builder selection
  • Image operations: Push, pull, and multi-platform manifest building
  • Working examples: All commands tested and verified

Example Usage

# Build for different architecture
PLATFORM=linux/arm64 make cns-image

# Use custom registry
IMAGE_REGISTRY=myregistry.azurecr.io make cns-image

# Use Podman instead of Docker
CONTAINER_BUILDER=podman make cns-image

The documentation follows the existing repository style and provides clear, actionable instructions for developers who need to build container images for these components.

Fixes #3722.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@Copilot Copilot AI changed the title [WIP] Update README for image generation Update README with Docker image generation documentation Jun 6, 2025
@Copilot Copilot AI requested a review from jpayne3506 June 6, 2025 22:33
@jpayne3506
Copy link
Contributor

@copilot combine make recipes documentation to be generic

Copy link
Contributor Author

Copilot AI commented Jun 6, 2025

@copilot combine make recipes documentation to be generic

Made the documentation generic with a standardized pattern that applies to all components. The documentation now uses <component>-image format and lists all available components instead of having separate sections for each one. This makes it more maintainable and concise. See commit cecb16b.

@jpayne3506
Copy link
Contributor

@copilot move these changes to ./doc/README.md

Copy link
Contributor Author

Copilot AI commented Jun 6, 2025

@copilot move these changes to ./doc/README.md

Moved the Docker image generation documentation from the main README.md to doc/README.md as requested. The main README now contains a simple reference to the detailed documentation. See commit 9aadc9e.

@jpayne3506
Copy link
Contributor

@copilot I meant docs/README.md

Copy link
Contributor Author

Copilot AI commented Jun 6, 2025

@copilot I meant docs/README.md

Moved the Docker image generation documentation to docs/README.md as requested. The content is now integrated into the existing docs/README.md file and the main README.md reference has been updated accordingly. See commit f99a9be.

@jpayne3506 jpayne3506 marked this pull request as ready for review June 6, 2025 23:15
@Copilot Copilot AI review requested due to automatic review settings June 6, 2025 23:15
@jpayne3506 jpayne3506 requested a review from a team as a code owner June 6, 2025 23:15
Copy link
Contributor

@Copilot 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 comprehensive documentation for Docker image generation in the repository, detailing component-specific build commands, prerequisites, and customization options.

  • Added a new "Docker Image Generation" section to docs/README.md covering prerequisites, available components, generic build patterns, example usage, and customization.
  • Updated the top-level README.md to reference the new Docker documentation.

Reviewed Changes

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

File Description
docs/README.md New section documenting Docker image generation, build patterns, and component-specific commands for networking.
README.md Added a link reference to the Docker image generation documentation in docs/README.md.
Comments suppressed due to low confidence (1)

docs/README.md:22

  • The 'Available Components' section lists 'acncli' and 'ipv6-hp-bpf', but the PR description mentions only four core components. Consider clarifying whether these additional components are part of the core set or updating the documentation to match the intended scope.
+- **acncli** - CNI manager

@jpayne3506
Copy link
Contributor

/azp run Azure Container Networking PR

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jpayne3506 jpayne3506 changed the title Update README with Docker image generation documentation docs: Update README with Docker image generation documentation Jun 6, 2025
@jpayne3506 jpayne3506 added the docs Documentation only label Jun 7, 2025
@jpayne3506
Copy link
Contributor

@copilot, document how GOOS=windows impacts image generation

Copy link
Contributor Author

Copilot AI commented Jun 7, 2025

@copilot, document how GOOS=windows impacts image generation

Added comprehensive Windows image generation documentation covering how GOOS impacts the build process, including cross-compilation behavior, Docker multi-stage targeting, and component-specific considerations. See commit 7a96168.

Copilot finished work on behalf of jpayne3506 June 7, 2025 00:50
Copy link

@NihaNallappagari NihaNallappagari left a comment

Choose a reason for hiding this comment

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

Thanks for updating the readme @jpayne3506

@jpayne3506
Copy link
Contributor

/azp run Azure Container Networking PR

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jpayne3506 jpayne3506 requested a review from rbtr June 9, 2025 17:31
docs/README.md Outdated
- `PLATFORM` - Target platform/architecture (default: linux/amd64)
- `IMAGE_REGISTRY` - Custom registry (default: acnpublic.azurecr.io)
- `CONTAINER_BUILDER` - Container builder (default: docker, alternative: podman)
- `GOOS` - Target operating system for cross-compilation (default: linux)
Copy link
Contributor

Choose a reason for hiding this comment

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

remove - GOOS is extracted by parsing PLATFORM and should not be set separately

Copy link
Contributor

Choose a reason for hiding this comment

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

@copilot continue removing documentation of GOOS

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed all GOOS documentation from docs/README.md as requested. The build system automatically extracts GOOS from the PLATFORM variable, so users only need to specify PLATFORM. See commit f0767b3.

Copy link
Contributor

Choose a reason for hiding this comment

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

I interpreted

OS ?= $(GOOS)
as we need to override the default for GOOS to change OS. Should we be instead manually overwriting OS?

Copy link
Contributor

Choose a reason for hiding this comment

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

well, i know i wrote code to parse the platform in to OS/ARCH somewhere, at some point. but you're right, that's not what's happening here now. i think especially for the container builds we should do it.
maybe we default platform as PLATFORM ?= $GOOS/$GOARCH to pick up the host platfom. but if it is set then we should parse $OS and $ARCH out of it, and then set any go invocation GOOS and GOARCH to those.

Copilot finished work on behalf of rbtr June 9, 2025 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation only
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update README for image generation
4 participants