
This constructs a VM's BMH network config secret, based on a template. It also integrates IPAM functionality into the controller. TODOs for subsequent patchsets: - manage VM mac addresses. - implement replacement of e.g. $vino.nodebridgegw - confirm the nameservers definition below works (it's a different field than we use in hostgenerator-m3) The current patchset generates a networkData like so from the sample CRs: links: - id: management name: management type: bridge mtu: 1500 # ethernet_mac_address: ?? bridgeName: vminfra-bridge - id: external name: external type: sriov-bond mtu: 9100 # ethernet_mac_address: ?? bond_miimon: 100 bond_mode: 802.3ad bond_xmit_hash_policy: layer3+4 pf: [enp29s0f0,enp219s1f1] vlan: 100 networks: - id: management type: ipv4 link: management ip_address: 192.168.2.10 #netmask: "TODO - see if needed when ip has CIDR range" dns_nameservers: [135.188.34.124] routes: - network: 10.0.0.0 netmask: 255.255.255.0 gateway: $vino.nodebridgegw - id: external type: ipv4 link: external ip_address: 169.0.0.10 #netmask: "TODO - see if needed when ip has CIDR range" dns_nameservers: [] routes: - network: 0.0.0.0 netmask: 0.0.0.0 gateway: 169.0.0.1 Change-Id: I99b1a104764687c8b84f2495591e0712bed73ae5
28 lines
876 B
Modula-2
28 lines
876 B
Modula-2
module vino
|
|
|
|
go 1.13
|
|
|
|
require (
|
|
github.com/Masterminds/goutils v1.1.1 // indirect
|
|
github.com/Masterminds/sprig v2.22.0+incompatible
|
|
github.com/evanphx/json-patch v4.9.0+incompatible
|
|
github.com/go-logr/logr v0.3.0
|
|
github.com/go-logr/zapr v0.2.0
|
|
github.com/golang/mock v1.4.4
|
|
github.com/huandu/xstrings v1.3.2 // indirect
|
|
github.com/kr/text v0.2.0 // indirect
|
|
github.com/metal3-io/baremetal-operator v0.0.0-20210111093319-93a6fd209b9a
|
|
github.com/mitchellh/copystructure v1.1.1 // indirect
|
|
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect
|
|
github.com/onsi/ginkgo v1.14.2
|
|
github.com/onsi/gomega v1.10.2
|
|
github.com/prometheus/common v0.10.0
|
|
github.com/stretchr/testify v1.6.1
|
|
go.uber.org/zap v1.15.0
|
|
k8s.io/api v0.20.2
|
|
k8s.io/apimachinery v0.20.2
|
|
k8s.io/client-go v0.20.2
|
|
sigs.k8s.io/controller-runtime v0.7.0
|
|
sigs.k8s.io/yaml v1.2.0
|
|
)
|