Skip to content

Commit cecb16b

Browse files
Copilotjpayne3506
andcommitted
Make Docker image generation documentation generic as requested
Co-authored-by: jpayne3506 <[email protected]>
1 parent 139b87e commit cecb16b

File tree

1 file changed

+34
-51
lines changed

1 file changed

+34
-51
lines changed

README.md

Lines changed: 34 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -39,80 +39,63 @@ $ make all-binaries
3939
Then follow the instructions for the plugin in [Documentation](docs/).
4040

4141
## Docker Image Generation
42-
This repository supports building Docker container images for the core networking components. The build system uses Docker or Podman to create multi-platform images.
42+
This repository supports building Docker container images for networking components using standardized make recipes. The build system uses Docker or Podman to create multi-platform images.
4343

4444
### Prerequisites
4545
- Docker or Podman installed and running
4646
- For multi-platform builds: `make qemu-user-static` (Linux only)
4747

4848
### Available Components
49+
- **acncli** - CNI manager
50+
- **azure-ipam** - Azure IP Address Management
51+
- **cni** - Container Network Interface
52+
- **cns** - Container Network Service
53+
- **npm** - Network Policy Manager
54+
- **ipv6-hp-bpf** - IPv6 Host Policy BPF
4955

50-
#### Container Network Service (CNS)
51-
```bash
52-
# Build CNS container image
53-
$ make cns-image
56+
### Generic Build Pattern
57+
All components follow the same make recipe pattern:
5458

55-
# View image name and tag
56-
$ make cns-image-name-and-tag
57-
```
58-
59-
#### Container Network Interface (CNI)
6059
```bash
61-
# Build CNI container image
62-
$ make cni-image
60+
# Build container image
61+
$ make <component>-image
6362

6463
# View image name and tag
65-
$ make cni-image-name-and-tag
66-
```
64+
$ make <component>-image-name-and-tag
6765

68-
#### Network Policy Manager (NPM)
69-
```bash
70-
# Build NPM container image
71-
$ make npm-image
72-
73-
# View image name and tag
74-
$ make npm-image-name-and-tag
75-
```
66+
# Push image to registry
67+
$ make <component>-image-push
7668

77-
#### Azure IP Address Management (Azure-IPAM)
78-
```bash
79-
# Build Azure-IPAM container image
80-
$ make azure-ipam-image
69+
# Pull image from registry
70+
$ make <component>-image-pull
8171

82-
# View image name and tag
83-
$ make azure-ipam-image-name-and-tag
72+
# Build multi-platform manifest
73+
$ make <component>-manifest-build
74+
$ make <component>-manifest-push
8475
```
8576

86-
### Customization Options
87-
You can customize the build by setting environment variables:
88-
77+
### Example Usage
8978
```bash
90-
# Build for different platform/architecture
91-
$ PLATFORM=linux/arm64 make cns-image
79+
# Build CNS image
80+
$ make cns-image
9281

93-
# Use custom image registry
94-
$ IMAGE_REGISTRY=myregistry.azurecr.io make cns-image
82+
# Build NPM image with custom platform
83+
$ PLATFORM=linux/arm64 make npm-image
84+
85+
# Build Azure-IPAM image with custom registry
86+
$ IMAGE_REGISTRY=myregistry.azurecr.io make azure-ipam-image
9587

9688
# Use Podman instead of Docker
97-
$ CONTAINER_BUILDER=podman make cns-image
89+
$ CONTAINER_BUILDER=podman make cni-image
9890
```
9991

100-
### Image Operations
101-
Each component supports additional operations:
102-
103-
```bash
104-
# Push image to registry
105-
$ make cns-image-push
106-
107-
# Pull image from registry
108-
$ make cns-image-pull
109-
110-
# Build multi-platform manifest
111-
$ make cns-manifest-build
112-
$ make cns-manifest-push
113-
```
92+
### Customization
93+
Environment variables for customizing builds:
94+
- `PLATFORM` - Target platform/architecture (default: linux/amd64)
95+
- `IMAGE_REGISTRY` - Custom registry (default: acnpublic.azurecr.io)
96+
- `CONTAINER_BUILDER` - Container builder (default: docker, alternative: podman)
11497

115-
Images are tagged with platform and version information (e.g., `linux-amd64-v1.2.3`) and published to the `acnpublic.azurecr.io` registry by default.
98+
Images are tagged with platform and version information and published to the configured registry.
11699

117100
## Contributions
118101
Contributions in the form of bug reports, feature requests and PRs are always welcome.

0 commit comments

Comments
 (0)