Init BM MCC+MOSK commit
Just put templates to the repo
MOSSUST-114
Change-Id: I2239dd7067d823d3ab15d1d46dc57fc2c7b9444b
diff --git a/bm_mcc_mosk/kaas-mgmt/baremetalhostprofiles.yaml b/bm_mcc_mosk/kaas-mgmt/baremetalhostprofiles.yaml
new file mode 100644
index 0000000..81be899
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/baremetalhostprofiles.yaml
@@ -0,0 +1,182 @@
+# BareMetalHostProfile resource allows you to define how the storage
+# devices and the operating system are provisioned and configured.
+apiVersion: metal3.io/v1alpha1
+metadata:
+ namespace: default
+ name: default-simple-since-2-24
+ labels:
+ kaas.mirantis.com/defaultBMHProfile: 'true'
+kind: BareMetalHostProfile
+spec:
+ # List of definitions of the physical storage devices. To configure more
+ # storage devices per host, add additional devices to this list.
+ # Each section in the list allows you to define disk parameters and
+ # restrictions in the 'device' field, and a list of partitions to be
+ # created on the device in the 'paritions' field.
+ devices:
+ # Define configuration of the first device on the host. This device
+ # will be partitioned and used as a system boot device. Minimal size
+ # for this device is 60Gib. If your device is smaller, change
+ # the 'minSize' parameter in the device definition appropriately.
+ # Use of a system device smaller than 60Gib is not recommended.
+ - device:
+ # Use the appropriate name of the device in the system. '/dev/sda'
+ # typically defines the first device on a system with 2 disks.
+ #byName: /dev/sda
+ minSize: 60Gi
+ # Deprecated. 'wipe' field, if set to 'true', forces the Container Cloud
+ # bare metal provisioning system to erase the contents of the device before using it.
+ #wipe: true
+ wipeDevice:
+ eraseMetadata:
+ enabled: true
+ # eraseDevice:
+ # timeout: 3600
+ # blkdiscard:
+ # enabled: false
+ # zeroout: "fallback"
+ # userDefined:
+ # enabled: false
+ # command: ""
+ # script: ""
+ # Do not change the names of partitions in this section.
+ # They are defined as expected by the Ubuntu operating system that
+ # will be installed.
+ partitions:
+ - name: bios_grub
+ # 4Mb boot partition is required for legacy (non-UEFI) systems.
+ size: 4Mi
+ partflags: ['bios_grub']
+ - name: uefi
+ partflags: ['esp']
+ size: 200Mi
+ - name: config-2
+ # Size of this partition is limited to 64Mb.
+ size: 64Mi
+ - name: lvm_root_part
+ # The 0 size for the partition means that this partition will
+ # use all remaining space on the device. Change it only if
+ # you want to have a root file system of specific size.
+ # WARNING: only last one partition on disk could be set as "0" size.
+ size: 0
+ # Define configuration of the second device on the host. This device
+ # will be used to store application data for management services of
+ # Container Cloud.
+ # The application data is stored in directories on this device,
+ # mounted as volumes to the application pods.
+ - device:
+ # Use the appropriate name of the device in the system. Typically,
+ # '/dev/sdb' defines the second device on a system with 3 disks.
+ #byName: /dev/sdb
+ minSize: 30Gi
+ # Deprecated. 'wipe' field, if set to 'true', forces the Container Cloud
+ # bare metal provisioning system to erase the contents of the device before using it.
+ #wipe: true
+ wipeDevice:
+ eraseMetadata:
+ enabled: true
+ # eraseDevice:
+ # timeout: 3600
+ # blkdiscard:
+ # enabled: false
+ # zeroout: "fallback"
+ # userDefined:
+ # enabled: false
+ # command: ""
+ # script: ""
+ # This device is partitioned for use by local volume provisioner.
+ partitions:
+ - name: lvm_lvp_part
+ # The 0 size for the partition means that this partition will
+ # use all remaining space on the device.
+ # WARNING: only last one partition on disk could be set as "0" size.
+ size: 0
+ volumeGroups:
+ - name: lvm_root
+ devices:
+ - partition: lvm_root_part
+ - name: lvm_lvp
+ devices:
+ - partition: lvm_lvp_part
+ logicalVolumes:
+ - name: root
+ vg: lvm_root
+ # If you set the size to 0, the logical volume will use all available
+ # space in its volume group.
+ # WARNING: only last one partition on disk could be set as "0" size.
+ size: 0
+ - name: lvp
+ vg: lvm_lvp
+ # If you set the size to 0, the logical volume will use all available
+ # space in its volume group.
+ # WARNING: only last one partition on disk could be set as "0" size.
+ size: 0
+ fileSystems:
+ - fileSystem: vfat
+ partition: config-2
+ - fileSystem: vfat
+ partition: uefi
+ mountPoint: /boot/efi
+ - fileSystem: ext4
+ logicalVolume: root
+ mountPoint: /
+ - fileSystem: ext4
+ logicalVolume: lvp
+ mountPoint: /mnt/local-volumes/
+ preDeployScript: |
+ #!/bin/bash -ex
+ echo $(date) 'pre_deploy_script done' >> /root/pre_deploy_done
+ postDeployScript: |
+ #!/bin/bash -ex
+ echo $(date) 'post_deploy_script done' >> /root/post_deploy_done
+ grubConfig:
+ defaultGrubOptions:
+ - 'GRUB_DISABLE_RECOVERY="true"'
+ - 'GRUB_PRELOAD_MODULES=lvm'
+ - 'GRUB_TIMEOUT=20'
+ # 'kernelParameters' section defines parameters of the operating system.
+ # See comments for the individual options for more information.
+ kernelParameters:
+ sysctl:
+ # Please check list of prohibited to change options:
+ # https://docs.mirantis.com/mke/3.6/install/predeployment/set-up-kernel-default-protections.html
+ # With this setting, kernel logs will be available only to the 'root'
+ # user.
+ kernel.dmesg_restrict: "1"
+ # Controls whether core dumps will append the PID to the core filename
+ # useful for debugging multi-threaded applications.
+ kernel.core_uses_pid: "1"
+ # Increase system file descriptor limit up to
+ # 9223372036854775807 (0x7fffffffffffffff) on a 64-bit system.
+ # Linux kernel documentation suggests that inode-max should be 3-4 times
+ # larger than this value.
+ fs.file-max: "9223372036854775807"
+ # The Linux kernel provides the Asynchronous non-blocking I/O (AIO) feature that allows a
+ # process to initiate multiple I/O operations simultaneously without having to wait for any of them to complete.
+ # This helps boost performance for applications that are able to overlap processing and I/O.
+ fs.aio-max-nr: "1048576"
+ # The inotify API provides a mechanism for monitoring file system events.
+ # Inotify can be used to monitor individual files, or to monitor directories.
+ # When a directory is monitored, inotify will return events for the directory itself, and for files inside the directory.
+ fs.inotify.max_user_instances: "4096"
+ # This file contains the maximum number of memory map areas a process may have.
+ # Memory map areas are used as a side-effect of calling malloc, directly by mmap and mprotect, and also when loading shared libraries.
+ # While most applications need less than a thousand maps, certain programs,
+ # particularly malloc debuggers, may consume lots of them, e.g., up to one or two maps per allocation.
+ vm.max_map_count: "262144"
+ # This option enables "Loose mode" assymetric-routing between k8s-lcm (LCM network) and bond0 (PXE network).
+ # Required only during bootstrap process, since bootstrap-seed node might not
+ # contain all required networks. (For example, when only pxe network configured on seed node)
+ # For details, see
+ # https://docs.mirantis.com/container-cloud/latest/deployment-guide/deploy-bm-mgmt.html
+ net.ipv4.conf.all.rp_filter: "2"
+ net.ipv4.conf.k8s-lcm.rp_filter: "2"
+ net.ipv4.conf.bond0.rp_filter: "2"
+ fs.inotify.max_user_watches: "81920"
+ # 'modules' field contains a list of files to be created in the
+ # '/etc/modprobe.d/' directory and the contents of the files.
+ # Use them to configure specific kernel modules on your system.
+ #modules:
+ # - filename: kvm_intel.conf
+ # content: |
+ # options kvm_intel nested=1
diff --git a/bm_mcc_mosk/kaas-mgmt/baremetalhosts.yaml b/bm_mcc_mosk/kaas-mgmt/baremetalhosts.yaml
new file mode 100644
index 0000000..41591fc
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/baremetalhosts.yaml
@@ -0,0 +1,89 @@
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: BareMetalHostCredential
+metadata:
+ name: cz9040-bmc-credentials
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+spec:
+ username: engineer
+ password:
+ value: KBwdcRqwed3w2
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: BareMetalHostCredential
+metadata:
+ name: cz9041-bmc-credentials
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+spec:
+ username: engineer
+ password:
+ value: KBwdcRqwed3w2
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: BareMetalHostCredential
+metadata:
+ name: cz9042-bmc-credentials
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+spec:
+ username: engineer
+ password:
+ value: KBwdcRqwed3w2
+---
+apiVersion: metal3.io/v1alpha1
+kind: BareMetalHost
+metadata:
+ name: cz9040
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ baremetal: hw-cz9040
+ hostlabel.bm.kaas.mirantis.com/controlplane: "controlplane"
+ annotations:
+ "kaas.mirantis.com/baremetalhost-credentials-name": "cz9040-bmc-credentials"
+spec:
+ bootMode: legacy
+ online: true
+ bootMACAddress: 0c:c4:7a:aa:c9:02
+ bmc:
+ address: 185.8.58.246
+ credentialsName: 'cz9040-bmc-credentials'
+---
+apiVersion: metal3.io/v1alpha1
+kind: BareMetalHost
+metadata:
+ name: cz9041
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ baremetal: hw-cz9041
+ hostlabel.bm.kaas.mirantis.com/controlplane: "controlplane"
+ annotations:
+ "kaas.mirantis.com/baremetalhost-credentials-name": "cz9041-bmc-credentials"
+spec:
+ bootMode: legacy
+ online: true
+ bootMACAddress: 0c:c4:7a:aa:d5:60
+ bmc:
+ address: 185.8.58.243
+ credentialsName: 'cz9041-bmc-credentials'
+---
+apiVersion: metal3.io/v1alpha1
+kind: BareMetalHost
+metadata:
+ name: cz9042
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ baremetal: hw-cz9042
+ hostlabel.bm.kaas.mirantis.com/controlplane: "controlplane"
+ annotations:
+ "kaas.mirantis.com/baremetalhost-credentials-name": "cz9042-bmc-credentials"
+spec:
+ bootMode: legacy
+ online: true
+ bootMACAddress: 0c:c4:7a:aa:c9:3a
+ bmc:
+ address: 185.8.58.244
+ credentialsName: 'cz9042-bmc-credentials'
diff --git a/bm_mcc_mosk/kaas-mgmt/bootstrapregion.yaml b/bm_mcc_mosk/kaas-mgmt/bootstrapregion.yaml
new file mode 100644
index 0000000..687e29b
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/bootstrapregion.yaml
@@ -0,0 +1,7 @@
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: BootstrapRegion
+metadata:
+ name: region-one
+ namespace: default
+spec:
+ provider: baremetal
diff --git a/bm_mcc_mosk/kaas-mgmt/cluster.yaml b/bm_mcc_mosk/kaas-mgmt/cluster.yaml
new file mode 100644
index 0000000..1005e29
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/cluster.yaml
@@ -0,0 +1,105 @@
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: PublicKey
+metadata:
+ name: vkhlyunev
+ namespace: default
+spec:
+ publicKey: |
+ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDeGiSOs0zAwcxuc9y6BzidYFXQXLOLcBKSoW1tPYJ+bVGRwNRVh63/+/X+eOPbBp6xTNNHVyOpYHt1WUbIHsAqAx/XbzBp+j3/4+8+ucvWR3X9TTxK7Q+oB3SSy2iEeimiJmxfjiHu1hfcgN8L9YvXVquGC/EZbk/r27j7Gcxli7zesr9/kBBhigDSQeehJBJZ0ux3luVkjWSDYTeKqZhNNPFoD6eWmOfsAKNMhe/8IRD9e0zY4MsELi1tZl2zoQ69249e4M1aCuGxm+t+tHLzywX0tVZmM1yX7TDuszHbiii8HrjNwB1/K80HRwRrwVIne9P7wFSlC2exLkdfWd2D
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: PublicKey
+metadata:
+ name: maintenance-ci-robot
+ namespace: default
+spec:
+ publicKey: |
+ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDci6MBY68s3FJ9V1OP5vdtVo/daJnkNXCPSPYbCX8/d0E3UJKgE81YvsxfuKp3r1rUNwTuGnkq+VUWcbIgpQNy69OuKxQkoGsRgYTA8n4ZZcuWz+dVenP90xLYHcnyACg63HUVEp5foLvu1WzOdH2A4bHmsl0ePM5IdnFyToHj+Nhwz1NSvbK1OkQHoEcIbkbIkIa/kWY2mgEIIUgb9YmaCI96eiVtQpFPQ4k7hpdrUAkG4e0jT8JA3zQoB++S12p0d0K3SQtJ3+YATUm+rKnHchHZ/uEAgBgoOLiu99p7Aiie76jlGxZp8A/hPqU/zS61z7ER4lJeyR/pXh53Ja+1 maintenance-ci
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: PublicKey
+metadata:
+ name: rlubianyi
+ namespace: default
+spec:
+ publicKey: |
+ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCXWwy6p3t4AGvaCtFDJxqKZiPDotJnbu2IKg2p7sl7YXQw+APLKk9maHyUehQQuGzidgBZpmBOMAXENcO1FGFj56cnp4W9tldTiRq1bWcUMq42wfNwIToP6dAXj5ZyhL+UZj1GsCThSasDhFe4Xife0cn69KHJqtmahApQK6D7tpZr2UNDYNWh/2JIrUOcJXZU+BqNg7zm1KNb6e9lKXL6KLDeaCiQ0bj+L/unqepLdg26eO7AQSZ/rt2qAnbfcquozECtDhT4cbK8q9xJODlJQ3eQGOgTH3m8jGijL+3UdPFUzbo4KwSK4V9FmB711HVBCQM4nlH9zumIUSxutnkd rlubianyi@rlubianyi-pc
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: PublicKey
+metadata:
+ name: pglazov
+ namespace: default
+spec:
+ publicKey: |
+ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDhZxqF+NSuP+Dr2nmGHf4NIpH2xWSmq+UE/HGP6j81rKSBZeRb2SuRXLtLVh3NZ+3GLa4UQGvedcnsqzgvSt05LYujloHnLxIsrsOWbLxOcdUYkorhXenGKBxKopwViRNV2PovMAnwyZ27GkXH8RQ52XISOdTIIV7r8M3kLpxCor2jHnOzJOcr7rhLeSFTK5zw6//T3S+IOQ5/HEs+8NK1sNw2lxBTuk+dAydiaCsQqm4GMl5vZSy0j7cnsy+lq69zN2/Bi4JzKLDKF2ap4zDh/ELhUBoQhh12T0djFV9Qv9fTWI4LUW8cVyqxbfreJrZqSAyMgSRrGSUBclFTmn5Z pavel@pavel-All-Series
+---
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: PublicKey
+metadata:
+ name: dmeltsaykin
+ namespace: default
+spec:
+ publicKey: |
+ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCqfNIy3WuxzRzOY/GBNGOnP5UrCFWZ8uMzW6hEl4wgIEYYIcv8o+C1/hvrfHimG/I/rAwYRS6Dx0bZ7m49zATNxe+EVer3BV63ru34Hzel/XxxyD34ULmrDgvP3olaAKFI17gVOFQ7hCBzDRp3s4YN3ojQspPyeiO+Jt8OwVomxJWgLauAHhl7Z/XPVHpT/fssJGG/eC4oOz4RZ4jAk0BH3Yl8s63grfwrgB79H/+nr0UvBdTkBn3T5WiC4gxnm+jQQwci7/BLQsg1Z3OykfTuyftIexNyVVy/SmdsGi37RJGFKRMMovoZx+261JgaHWBoHqBJa5UpV2usi9z3Py2z avgoor@MacBook-Pro-Denis.local
+---
+apiVersion: cluster.k8s.io/v1alpha1
+kind: Cluster
+metadata:
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ name: kaas-mgmt
+ namespace: default
+spec:
+ clusterNetwork:
+ pods:
+ cidrBlocks:
+ - 10.200.0.0/16
+ services:
+ cidrBlocks:
+ - 10.201.0.0/16
+ providerSpec:
+ value:
+ kind: BaremetalClusterProviderSpec
+ release: mke-16-1-0-3-7-5
+ apiVersion: baremetal.k8s.io/v1alpha1
+ dedicatedControlPlane: false
+ dedicatedMetallbPools: true
+ publicKeys:
+ - name: vkhlyunev
+ - name: maintenance-ci-robot
+ - name: pglazov
+ - name: dmeltsaykin
+ - name: rlubianyi
+ loadBalancerHost: ""
+ dnsNameservers:
+ - 172.18.176.6
+ helmReleases:
+ - name: metallb
+ values: {}
+ - name: stacklight
+ values:
+ elasticsearch:
+ persistentVolumeClaimSize: 30Gi
+ highAvailabilityEnabled: true
+ logging:
+ enabled: true
+ prometheusServer:
+ persistentVolumeClaimSize: 16Gi
+ kaas:
+ release: kaas-2-26-0
+ management:
+ enabled: true
+ regional:
+ - helmReleases:
+ - name: baremetal-operator
+ values: {}
+ - name: baremetal-provider
+ values:
+ customHostnamesEnabled: true
+ dnsmasq:
+ dynamic_bootp: true
+ - name: kaas-ipam
+ values: {}
+ provider: baremetal
diff --git a/bm_mcc_mosk/kaas-mgmt/ipam-objects.yaml b/bm_mcc_mosk/kaas-mgmt/ipam-objects.yaml
new file mode 100644
index 0000000..eb5535d
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/ipam-objects.yaml
@@ -0,0 +1,209 @@
+---
+# This template allows you to configure networking for servers
+# of the management cluster of Mirantis Container Cloud. Network
+# configuration requires the following resources.
+
+# WARNING: Since Container Cloud 2.24, the default networking
+# definition schema has been significantly changed.
+# Older templates will not work for 2.24+ release bootstrap deployment.
+# For details, see
+# https://docs.mirantis.com/container-cloud/latest/deployment-guide/deploy-bm-mgmt.html
+
+# The 'mgmt-lb-pxe' Subnet object defines the range of IP addresses
+# used by MetalLB to expose services in the PXE network. This
+# includes Ironic API (bare metal provisioning server), HTTP server
+# that provides images for network boot and server provisioning,
+# and the caching server for accessing the Container Cloud artifacts
+# deployed on the hosts.
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-lb-pxe
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ ipam/SVC-MetalLB: "presents"
+ metallb/address-pool-auto-assign: "false"
+ metallb/address-pool-name: services-pxe
+ metallb/address-pool-protocol: layer2
+spec:
+ cidr: 172.16.180.0/23
+ includeRanges:
+ - 172.16.181.10-172.16.181.13
+---
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-pxe
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ ipam/SVC-dhcp-range: "presents"
+spec:
+ cidr: 172.16.180.0/23
+ includeRanges:
+ - 172.16.181.14-172.16.181.30
+
+---
+# The 'mgmt-pxe-nics' Subnet object defines the range of IP addresses
+# for NIC IPs, from the PXE range that will be allocated on the nodes NICs
+# in the PXE network after nodes provisioning.
+# Required to elliminate prossible dhcp routing issues.
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-pxe-nics
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ # Label 'ipam/SVC-pxe-nics' is mandatory for this type of network.
+ ipam/SVC-pxe-nics: "presents"
+spec:
+ cidr: 172.16.180.0/23
+ gateway: 172.16.180.1
+ includeRanges:
+ - 172.16.181.31-172.16.181.50
+
+---
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-k8s-api-lb
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ ipam/SVC-LBhost: "presents"
+spec:
+ cidr: 172.16.181.3/32
+ useWholeCidr: true
+---
+# The 'mgmt-nics' Subnet defines the range of IP addresses to be allocated
+# to the nodes in the management/LCM network. The IP address of Kubernetes
+# API endpoint for the cluster is excluded from that range. The
+# MetalLB address pools are also excluded from that range.
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-nics
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ ipam/SVC-k8s-lcm: "presents"
+spec:
+ cidr: 172.16.180.0/23
+ gateway: 172.16.180.1
+ nameservers:
+ - 172.18.176.6
+ - 8.8.8.8
+ includeRanges:
+ - 172.16.181.51-172.16.181.100
+
+---
+# The 'mgmt-k8s-lb' Subnet object defines the range of IP addresses
+# used by MetalLB to expose services in the LCM/Management network.
+# It defines the same MetalLB address pool that was previously defined
+# in MetalLB chart values configInline parameter (which is deprecated).
+# These services include Keycloak, MCC UI, Stacklight services,
+# and the caching server for accessing the Container Cloud artifacts
+# deployed on the hosts.
+apiVersion: "ipam.mirantis.com/v1alpha1"
+kind: Subnet
+metadata:
+ name: mgmt-k8s-lb
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ ipam/SVC-MetalLB: "presents"
+ metallb/address-pool-auto-assign: "true"
+ metallb/address-pool-name: default
+ metallb/address-pool-protocol: layer2
+spec:
+ cidr: 172.16.180.0/23
+ includeRanges:
+ - 172.16.181.101-172.16.181.140
+
+---
+apiVersion: ipam.mirantis.com/v1alpha1
+kind: MetalLBConfigTemplate
+metadata:
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ name: kaas-mgmt-metallb
+ namespace: default
+spec:
+ templates:
+ l2Advertisements: |
+ - name: default
+ spec:
+ ipAddressPools:
+ - default
+ - services-pxe
+---
+# L2Template allows you to create advanced host networking
+# configurations for your management cluster. For example,
+# you can create bond interfaces on top of physical interfaces
+# on the host, or use multiple subnets to separate different
+# types of network traffic.
+# More elaborate network configurations for the management cluster
+# require changes in this resource template and potential
+# adding of more Subnet resources for other networks.
+# For more details, see
+# https://docs.mirantis.com/container-cloud/latest/deployment-guide/deploy-bm-mgmt.rst
+apiVersion: ipam.mirantis.com/v1alpha1
+kind: L2Template
+metadata:
+ name: default
+ namespace: default
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ ipam/DefaultForCluster: "1"
+spec:
+ autoIfMappingPrio:
+ - provision
+ - enp
+ - eno
+ - ens
+ # The 'l3Layout' section defines the list of subnets to be used in the
+ # 'npTemplate' field.
+ l3Layout:
+ - scope: namespace
+ # 'subnetName' defines the name of the subnet that is used
+ # to refer to it throughout the 'npTemplate' below.
+ subnetName: kaas-mgmt
+ # 'labelSelector' is the combination of labels that allows
+ # detecting a unique subnet. These labels refer to the Subnet object.
+ labelSelector:
+ kaas.mirantis.com/provider: baremetal
+ ipam/SVC-k8s-lcm: "presents"
+ - scope: namespace
+ subnetName: mgmt-pxe
+ labelSelector:
+ kaas.mirantis.com/provider: baremetal
+ ipam/SVC-pxe-nics: "presents"
+ # The following is the template used to generate a netplan configuration
+ # file for Ubuntu. It contains an example of the definition of ethernet
+ # interfaces, with assigned addresses from the subnets defined in the 'l3Layout'
+ # field above. The gateway and nameservers are also
+ # taken from the subnet using the L2Temlpate-specific macros.
+ npTemplate: |
+ version: 2
+ renderer: networkd
+ ethernets:
+ {{nic 0}}:
+ dhcp4: false
+ dhcp6: false
+ addresses:
+ - {{ip "0:kaas-mgmt"}}
+ gateway4: {{gateway_from_subnet "kaas-mgmt"}}
+ nameservers:
+ addresses: {{nameservers_from_subnet "kaas-mgmt"}}
+ match:
+ macaddress: {{mac 0}}
+ set-name: {{nic 0}}
\ No newline at end of file
diff --git a/bm_mcc_mosk/kaas-mgmt/machines.yaml b/bm_mcc_mosk/kaas-mgmt/machines.yaml
new file mode 100644
index 0000000..3e1d6b0
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/machines.yaml
@@ -0,0 +1,48 @@
+apiVersion: "cluster.k8s.io/v1alpha1"
+kind: MachineList
+items:
+- apiVersion: "cluster.k8s.io/v1alpha1"
+ kind: Machine
+ metadata:
+ name: cz9040
+ labels: &cp_labels
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ cluster.sigs.k8s.io/control-plane: "true"
+ spec:
+ providerSpec:
+ value: &cp_value
+ apiVersion: "baremetal.k8s.io/v1alpha1"
+ kind: "BareMetalMachineProviderSpec"
+ hostSelector:
+ matchLabels:
+ baremetal: hw-cz9040
+
+- apiVersion: "cluster.k8s.io/v1alpha1"
+ kind: Machine
+ metadata:
+ name: cz9041
+ labels:
+ <<: *cp_labels
+ spec:
+ providerSpec:
+ value:
+ <<: *cp_value
+ hostSelector:
+ matchLabels:
+ baremetal: hw-cz9041
+
+- apiVersion: "cluster.k8s.io/v1alpha1"
+ kind: Machine
+ metadata:
+ name: cz9042
+ labels:
+ <<: *cp_labels
+ spec:
+ providerSpec:
+ value:
+ <<: *cp_value
+ hostSelector:
+ matchLabels:
+ baremetal: hw-cz9042
+
diff --git a/bm_mcc_mosk/kaas-mgmt/metallbconfig.yaml b/bm_mcc_mosk/kaas-mgmt/metallbconfig.yaml
new file mode 100644
index 0000000..8c218d0
--- /dev/null
+++ b/bm_mcc_mosk/kaas-mgmt/metallbconfig.yaml
@@ -0,0 +1,19 @@
+---
+# MetalLBConfig object serves for monitoring of MetalLB address advertisement
+# configuration since MCC 2.24. It can contain a link to MetalLBConfigTemplate
+# or full definition of MetalLB API objects.
+# The example below consumes "kaas-mgmt-metallb" MetalLBConfigTemplate object.
+# Operator can monitor the status of MetalLB configuration of the target
+# cluster using "status" of MetalLBConfig.
+# See MCC documentation for detailed description of MetalLB configuration using
+# MetalLBConfig and MetalLBConfigTemplate objects.
+apiVersion: kaas.mirantis.com/v1alpha1
+kind: MetalLBConfig
+metadata:
+ labels:
+ kaas.mirantis.com/provider: baremetal
+ cluster.sigs.k8s.io/cluster-name: kaas-mgmt
+ name: kaas-mgmt-metallb
+ namespace: default
+spec:
+ templateName: kaas-mgmt-metallb