Skip to content

Commit 5a465b0

Browse files
feat: expose network aliases to templates
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 2ec1acf commit 5a465b0

3 files changed

Lines changed: 3 additions & 0 deletions

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,7 @@ type Address struct {
282282
type Network struct {
283283
IP string
284284
Name string
285+
Aliases []string
285286
Gateway string
286287
EndpointID string
287288
IPv6Gateway string

internal/context/context.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ func SetDockerEnv(d *docker.Env) {
5555
type Network struct {
5656
IP string
5757
Name string
58+
Aliases []string
5859
Gateway string
5960
EndpointID string
6061
IPv6Gateway string

internal/generator/generator.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -460,6 +460,7 @@ func (g *generator) getContainers(config config.Config) ([]*context.RuntimeConta
460460
network := context.Network{
461461
IP: v.IPAddress,
462462
Name: k,
463+
Aliases: append([]string{}, v.Aliases...),
463464
Gateway: v.Gateway,
464465
EndpointID: v.EndpointID,
465466
IPv6Gateway: v.IPv6Gateway,

0 commit comments

Comments
 (0)