Skip to content

Commit

Permalink
Merge branch 'collect-bgp-neighbor-infos' of https://github.com/metal…
Browse files Browse the repository at this point in the history
…-stack/metal-roles into collect-bgp-neighbor-infos
  • Loading branch information
majst01 committed Nov 25, 2024
2 parents 055d58b + 667be2f commit acfd974
Show file tree
Hide file tree
Showing 18 changed files with 118 additions and 25 deletions.
10 changes: 9 additions & 1 deletion control-plane/roles/gardener/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Check out the Gardener project for further documentation on [gardener.cloud](htt
| gardener_backup_infrastructure_secret | | Specifies the secret for the backup infrastructure |
| gardener_soil_name | | The name of the initial `Seed` (used for spinning up shooted seeds) |
| gardener_soil_kubeconfig_file_path | | The kubeconfig path to the initial seed cluster |
| gardener_soil_vertical_pod_autoscaler_enabled | | Enables the VPA for the intial seed cluster |
| gardener_soil_vertical_pod_autoscaler_enabled | | Enables the VPA for the initial seed cluster |
| gardener_soil_project_owner_name | | Specifies the owner name for the project that the initial seed uses to set up shooted seeds |
| gardener_soil_project_members | | Specifies the members of the soil project. Each member requires a `name` and a `role`. Optionally, and array of `roles` can be specified. Example: `{"name": "admin", "role": "admin", "roles": ["owner"]}` |
| gardener_gardenlet_shoot_concurrent_syncs | | Specifies the amount of concurrent shoot syncs for the Gardenlet |
Expand Down Expand Up @@ -96,10 +96,14 @@ This includes the metal-stack extension provider called [gardener-extension-prov
| gardener_extension_networking_cilium_enabled | | If enabled, deploys the gardener-networking-extension-cilium |
| gardener_extension_shoot_cert_service_enabled | | If enabled, deploys the gardener-extension-shoot-cert-service |
| gardener_extension_shoot_dns_service_enabled | | If enabled, deploys the gardener-extension-shoot-dns-service |
| gardener_extension_backup_s3_enabled | | If enabled, deploys the gardener-extension-backup-s3 |
| gardener_extension_dns_powerdns_enabled | | If enabled, deploys the gardener-extension-dns-powerdns |
| gardener_os_controller_repo_ref | | A repo reference for deploying the [os-metal-extension](https://github.com/metal-stack/os-metal-extension/) |
| gardener_networking_cilium_repo_ref | | A repo reference for deploying the [gardener-extension-networking-cilium](https://github.com/gardener/gardener-extension-networking-cilium) |
| gardener_extension_provider_metal_repo_ref | | A repo reference for deploying the [gardener-extension-provider-metal](https://github.com/metal-stack/gardener-extension-provider-metal) |
| gardener_shoot_dns_service_repo_ref | | A repo reference for deploying the [gardener-extension-shoot-dns-service](https://github.com/gardener/gardener-extension-shoot-dns-service) |
| gardener_extension_backup_s3_repo_ref | | A repo reference for deploying the [gardener-extension-backup-s3](https://github.com/metal-stack/gardener-extension-backup-s3) |
| gardener_extension_dns_powerdns_repo_ref | | A repo reference for deploying the [gardener-extension-dns-powerdns](https://github.com/metal-stack/gardener-extension-dns-powerdns) |
| gardener_metal_admission_replicas | | Specifies the amount of metal-admission webhook replicas |
| gardener_metal_admission_vpa | | Enables the VPA for the metal-admission webhook |
| gardener_extension_provider_metal_cluster_audit_enabled | | Enables the audit functionality of the GEPM |
Expand All @@ -122,6 +126,10 @@ This includes the metal-stack extension provider called [gardener-extension-prov
| gardener_shoot_dns_service_image_vector_overwrite | | Allows overriding the image vector for the shoot-dns-service extension |
| gardener_shoot_dns_service_dns_controller_manager_image_name | | Setting an explicit image name for the dns-controller-manager |
| gardener_shoot_dns_service_dns_controller_manager_image_tag | | Setting an explicit image tag for the dns-controller-manager |
| gardener_extension_backup_s3_image_name | | Setting an explicit image name for the gardener-extension-backup-s3 |
| gardener_extension_backup_s3_image_tag | | Setting an explicit image tag for the gardener-extension-backup-s3 |
| gardener_extension_dns_powerdns_image_name | | Setting an explicit image name for the gardener-extension-dns-powerdns |
| gardener_extension_dns_powerdns_image_tag | | Setting an explicit image tag for the gardener-extension-dns-powerdns |

### Certificates

Expand Down
4 changes: 4 additions & 0 deletions control-plane/roles/gardener/defaults/main/extensions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,15 @@ gardener_extension_provider_gcp_enabled: true
gardener_extension_provider_metal_enabled: true
gardener_extension_shoot_cert_service_enabled: true
gardener_extension_shoot_dns_service_enabled: true
gardener_extension_dns_powerdns_enabled: false
gardener_extension_backup_s3_enabled: false

gardener_extension_provider_metal_repo_ref: "{{ gardener_extension_provider_metal_image_tag }}"
gardener_networking_cilium_repo_ref: "gardener/gardener-extension-networking-cilium/{{ gardener_networking_cilium_image_tag }}"
gardener_os_controller_repo_ref: "{{ gardener_os_controller_image_tag }}"
gardener_shoot_dns_service_repo_ref: "gardener/gardener-extension-shoot-dns-service/{{ gardener_shoot_dns_service_image_tag }}"
gardener_extension_backup_s3_repo_ref: "metal-stack/gardener-extension-backup-s3/{{ gardener_extension_backup_s3_image_tag }}"
gardener_extension_dns_powerdns_repo_ref: "metal-stack/gardener-extension-dns-powerdns/{{ gardener_extension_dns_powerdns_image_tag }}"

gardener_metal_admission_replicas: 1
gardener_metal_admission_vpa: true
Expand Down
29 changes: 29 additions & 0 deletions control-plane/roles/gardener/tasks/extensions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,32 @@
- controller-deployment.yaml
- controller-registration.yaml
when: gardener_extension_shoot_dns_service_enabled

- name: "Register controller: dns powerdns"
k8s:
definition: "{{ lookup('template', 'powerdns/{{ item }}', split_lines=False) }}"
kubeconfig: "{{ gardener_kube_apiserver_kubeconfig_path }}"
apply: yes
register: result
until: result is success
retries: 10
delay: 6
loop:
- controller-deployment.yaml
- controller-registration.yaml
when: gardener_extension_dns_powerdns_enabled

- name: "Register controller: backup s3"
k8s:
definition: "{{ lookup('template', 'backup-s3/{{ item }}', split_lines=False) }}"
kubeconfig: "{{ gardener_kube_apiserver_kubeconfig_path }}"
apply: yes
tags: shoot-dns-service
register: result
until: result is success
retries: 10
delay: 6
loop:
- controller-deployment.yaml
- controller-registration.yaml
when: gardener_extension_backup_s3_enabled
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: backup-s3
helm:
rawChart: "{{ (lookup('url', 'https://raw.githubusercontent.com/' + gardener_extension_backup_s3_repo_ref + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].helm.rawChart }}"
values:
image:
repository: "{{ gardener_extension_backup_s3_image_name }}"
tag: "{{ gardener_extension_backup_s3_image_tag }}"
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
apiVersion: core.gardener.cloud/v1beta1
kind: ControllerRegistration
metadata:
name: backup-s3
annotations:
security.gardener.cloud/pod-security-enforce: baseline
spec:
deployment:
deploymentRefs:
- name: backup-s3
resources:
- kind: BackupBucket
type: S3
- kind: BackupEntry
type: S3
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
---
apiVersion: core.gardener.cloud/v1beta1
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: networking-calico
type: helm
providerConfig:
chart: "{{ (lookup('url', 'https://raw.githubusercontent.com/gardener/gardener-extension-networking-calico/' + gardener_networking_calico_image_tag + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].providerConfig.chart }}"
helm:
rawChart: "{{ (lookup('url', 'https://raw.githubusercontent.com/gardener/gardener-extension-networking-calico/' + gardener_networking_calico_image_tag + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].helm.rawChart }}"
values:
image:
repository: "{{ gardener_networking_calico_image_name }}"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: powerdns
helm:
rawChart: "{{ (lookup('url', 'https://raw.githubusercontent.com/' + gardener_extension_dns_powerdns_repo_ref + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].helm.rawChart }}"
values:
image:
repository: "{{ gardener_extension_dns_powerdns_image_name }}"
tag: "{{ gardener_extension_dns_powerdns_image_tag }}"
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
apiVersion: core.gardener.cloud/v1beta1
kind: ControllerRegistration
metadata:
name: powerdns
annotations:
security.gardener.cloud/pod-security-enforce: baseline
spec:
deployment:
deploymentRefs:
- name: powerdns
resources:
- kind: DNSRecord
type: powerdns
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
---
apiVersion: core.gardener.cloud/v1beta1
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: extension-shoot-dns-service
type: helm
providerConfig:
chart: "{{ (lookup('url', 'https://raw.githubusercontent.com/' + gardener_shoot_dns_service_repo_ref + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].providerConfig.chart }}"
helm:
rawChart: "{{ (lookup('url', 'https://raw.githubusercontent.com/' + gardener_shoot_dns_service_repo_ref + '/example/controller-registration.yaml', split_lines=False) | from_yaml_all | list)[0].helm.rawChart }}"
values:
image:
repository: "{{ gardener_shoot_dns_service_image_name }}"
Expand Down
14 changes: 6 additions & 8 deletions control-plane/roles/gardener/test/dns_extension_template_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,12 @@ def test_shoot_dns_extension_controller_deployment_template(self, mock_urlopen):
cm.getcode.return_value = 200
cm.read.return_value = '''
---
apiVersion: core.gardener.cloud/v1beta1
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: extension-shoot-dns-service
type: helm
providerConfig:
chart: a-chart
helm:
rawChart: a-chart
values:
image:
tag: v1.48.0
Expand Down Expand Up @@ -50,13 +49,12 @@ def test_shoot_dns_extension_controller_deployment_template(self, mock_urlopen):

expected = '''
---
apiVersion: core.gardener.cloud/v1beta1
apiVersion: core.gardener.cloud/v1
kind: ControllerDeployment
metadata:
name: extension-shoot-dns-service
type: helm
providerConfig:
chart: "a-chart"
helm:
rawChart: "a-chart"
values:
image:
repository: "extension-image"
Expand Down
4 changes: 2 additions & 2 deletions control-plane/roles/isolated-clusters/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# isolated clusters

Contains roles for deploying addtional services for the isolated cluster feature as described [here](https://docs.metal-stack.io/stable/overview/isolated-kubernetes/).
Contains roles for deploying additional services for the isolated cluster feature as described [here](https://docs.metal-stack.io/stable/overview/isolated-kubernetes/).

It contains the services:

Expand All @@ -17,7 +17,7 @@ The `control-plane-defaults` folder contains defaults that are used by multiple

| Name | Mandatory | Description |
| ---------------------------------------------------------------- | --------- | ------------------------------------------------------------------------------------------------ |
| isolated_clusters_virtual_garden_kubeconfig | | The kubeconfig to access the virutal garden as a string value. |
| isolated_clusters_virtual_garden_kubeconfig | | The kubeconfig to access the virtual garden as a string value. |
| isolated_clusters_ntp_image_name | | The image name of the ntp service for the partition. |
| isolated_clusters_ntp_image_tag | yes | The tag or version of the ntp service container image. |
| isolated_clusters_ntp_namespace | | The namespace to deploy the ntp server to. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ data:
}
],
"thresholds": "",
"title": "Maximum Node Cound ($iaas)",
"title": "Maximum Node Count ($iaas)",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2323,7 +2323,7 @@ data:
"uid": "prometheus"
},
"decimals": null,
"description": "Count of Shoots which have nginx ingress conroller addon enabled.",
"description": "Count of Shoots which have nginx ingress controller addon enabled.",
"format": "none",
"gauge": {
"maxValue": 100,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2086,7 +2086,7 @@ data:
"refId": "A"
}
],
"title": "Tranceiver Info",
"title": "Transceiver Info",
"transformations": [
{
"id": "seriesToRows",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ additionalPrometheusRulesMap:
labels:
severity: "warning"
annotations:
description: "{{ $value }}% of {{ $labels.networkId }} Internet IP adresses in {{ $labels.partition }} are in use."
description: "{{ $value }}% of {{ $labels.networkId }} Internet IP addresses in {{ $labels.partition }} are in use."
- alert: NetworkPrefixCapacityLow
expr: avg(metal_network_prefix_used{isPrivateSuper="true"}) by (partition, networkId) / avg(metal_network_prefix_available{isPrivateSuper="true"}) by (partition, networkId) * 100 > 80
for: 10m
Expand Down
4 changes: 4 additions & 0 deletions defaults/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ metal_stack_release:
gardener_mcm_provider_metal_image_tag: "docker-images.metal-stack.gardener.machine-controller-manager-provider-metal.tag"
gardener_extension_audit_image_name: "docker-images.metal-stack.gardener.gardener-extension-audit.name"
gardener_extension_audit_image_tag: "docker-images.metal-stack.gardener.gardener-extension-audit.tag"
gardener_extension_backup_s3_image_tag: "docker-images.metal-stack.gardener.gardener-extension-backup-s3.tag"
gardener_extension_backup_s3_image_name: "docker-images.metal-stack.gardener.gardener-extension-backup-s3.name"
gardener_extension_dns_powerdns_image_tag: "docker-images.metal-stack.gardener.gardener-extension-dns-powerdns.tag"
gardener_extension_dns_powerdns_image_name: "docker-images.metal-stack.gardener.gardener-extension-dns-powerdns.name"
# kubernetes
csi_lvm_controller_image_tag: "docker-images.metal-stack.kubernetes.csi-lvm-controller.tag"
csi_lvm_controller_image_name: "docker-images.metal-stack.kubernetes.csi-lvm-controller.name"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ groups:
labels:
severity: critical
annotations:
descritption: "HAProxy reports all servers are unhealthy for {{ $labels.proxy }}"
description: "HAProxy reports all servers are unhealthy for {{ $labels.proxy }}"
2 changes: 1 addition & 1 deletion partition/roles/sonic-upgrade/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ It depends on the `switch_facts` module from `ansible-common`, so make sure modu

| Name | Mandatory | Description |
| ------------------------ | --------- | ------------------------------------------------------------------------------------------------------------------- |
| sonic_upgrade_host | yes | The host from which to dowload the image. |
| sonic_upgrade_host | yes | The host from which to download the image. |
| sonic_upgrade_image_path | | The path to the image. If this is given and not `sonic_upgrade_host`, the image is pushed to the device by ansible. |
| sonic_upgrade_vrf | | The vrf used for pulling the upgrade image. |
| sonic_upgrade_protocol | | The protocol (http or https) to use when downloading the sonic image. |
Expand Down

0 comments on commit acfd974

Please sign in to comment.