Skip to content

Commit f1f692c

Browse files
committed
compose: Make use netplan's nic glob support
This way we don't need to hard code any nic names or update if things change. Signed-off-by: Manuel Mendez <[email protected]>
1 parent d47c9ee commit f1f692c

File tree

3 files changed

+21
-21
lines changed

3 files changed

+21
-21
lines changed

deploy/compose/create-tink-records/manifests/template/ubuntu-equinix-metal.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,13 @@ tasks:
8080
DEST_PATH: /etc/netplan/config.yaml
8181
CONTENTS: |
8282
network:
83-
version: 2
84-
renderer: networkd
85-
ethernets:
86-
enp1s0f0:
87-
dhcp4: true
83+
version: 2
84+
renderer: networkd
85+
ethernets:
86+
id0:
87+
match:
88+
name: en*
89+
dhcp4: true
8890
UID: 0
8991
GID: 0
9092
MODE: 0644

deploy/compose/create-tink-records/manifests/template/ubuntu-libvirt.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,13 +61,13 @@ tasks:
6161
DEST_PATH: /etc/netplan/config.yaml
6262
CONTENTS: |
6363
network:
64-
version: 2
65-
renderer: networkd
66-
ethernets:
67-
ens5:
68-
dhcp4: true
69-
ens6:
70-
dhcp4: true
64+
version: 2
65+
renderer: networkd
66+
ethernets:
67+
id0:
68+
match:
69+
name: en*
70+
dhcp4: true
7171
UID: 0
7272
GID: 0
7373
MODE: 0644

deploy/compose/create-tink-records/manifests/template/ubuntu.yaml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -61,15 +61,13 @@ tasks:
6161
DEST_PATH: /etc/netplan/config.yaml
6262
CONTENTS: |
6363
network:
64-
version: 2
65-
renderer: networkd
66-
ethernets:
67-
enp0s3:
68-
dhcp4: true
69-
enp0s8:
70-
dhcp4: true
71-
ens33:
72-
dhcp4: true
64+
version: 2
65+
renderer: networkd
66+
ethernets:
67+
id0:
68+
match:
69+
name: en*
70+
dhcp4: true
7371
UID: 0
7472
GID: 0
7573
MODE: 0644

0 commit comments

Comments
 (0)