Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes required for running Gardener in the mini-lab. #365

Merged
merged 2 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions control-plane/roles/gardener/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ The deployment chart is taken from [garden-setup](https://github.com/gardener/ga
| ---------------------------------------------------- | --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| gardener_virtual_api_server_svc_cluster_ip_add | | An integer to "guess" a free IP for the service that allows the soil to internally communicate with the virtual garden |
| gardener_virtual_api_server_public_dns | | The DNS domain to reach the virtual garden API server on |
| gardener_virtual_api_server_public_port | | The port on which the virtual garden API server is available |
| gardener_virtual_api_replicas | | The amount of replicas of the virtual garden API server |
| gardener_virtual_api_server_healthcheck_static_token | yes | A static token for healthchecking the virtual garden API server |
| gardener_etcd_backup_schedule | | The backup schedule for the virtual garden ETCD |
| gardener_etcd_snapshot_period | | The snapshot period for the virtual garden ETCD |
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
gardener_virtual_api_server_svc_cluster_ip_add: 20
gardener_virtual_api_server_public_dns: gardener-kube-apiserver.{{ metal_control_plane_ingress_dns }}
gardener_virtual_api_server_public_port: 443
gardener_virtual_api_server_healthcheck_static_token:

gardener_etcd_backup_schedule: "0,5,10,15,20,25,30,35,40,45,50,55 * * * *"
Expand All @@ -15,6 +16,8 @@ gardener_etcd_resources:
cpu: 800m
memory: 8Gi

gardener_virtual_api_replicas: 3

gardener_virtual_api_oidc_issuer_url:
gardener_virtual_api_oidc_client_id:
gardener_virtual_api_oidc_username_claim:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ contexts:
clusters:
- cluster:
certificate-authority-data: {{ .Values.tls.kubeAPIServer.ca.crt | b64enc }}
server: https://{{ .Values.apiServer.hostname }}:443
server: https://{{ .Values.apiServer.hostname }}:{{ .Values.apiServer.adminKubeconfigPort }}
name: garden
users:
- name: admin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ replicas: 3
apiServer:
hostname: 127.0.0.1
serviceName: garden-kube-apiserver
adminKubeconfigPort: 443

oidc:
issuerURL:
Expand Down
2 changes: 1 addition & 1 deletion control-plane/roles/gardener/tasks/gardener.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,5 @@
delay: 6
until:
- lookup('k8s', api_version='apps/v1', kind='Deployment', namespace='garden', resource_name='gardener-apiserver').get('status', {}).get('readyReplicas', 0) >= 1
- lookup('k8s', api_version='apps/v1', kind='Deployment', namespace='garden', resource_name='garden-kube-apiserver').get('status', {}).get('readyReplicas', 0) >= 3
- lookup('k8s', api_version='apps/v1', kind='Deployment', namespace='garden', resource_name='garden-kube-apiserver').get('status', {}).get('readyReplicas', 0) >= gardener_virtual_api_replicas
- lookup('k8s', api_version='apps/v1', kind='Deployment', namespace='garden', resource_name='gardener-controller-manager').get('status', {}).get('readyReplicas', 0) >= 1
2 changes: 1 addition & 1 deletion control-plane/roles/gardener/tasks/virtual_garden.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,5 @@
- name: Wait for garden-kube-apiserver
wait_for:
host: "{{ gardener_virtual_api_server_public_dns }}"
port: "443"
port: "{{ gardener_virtual_api_server_public_port }}"
timeout: 60
2 changes: 1 addition & 1 deletion control-plane/roles/gardener/templates/etcd-values.j2
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ backup:
ecs:
endpoint: "{{ gardener_backup_infrastructure_secret.endpoint | b64decode }}"
accessKeyID: "{{ gardener_backup_infrastructure_secret.accessKeyID | b64decode }}"
secretAccessKey: "{{ gardener_backup_infrastructure_secret.secretAccessKey | b64decode}}"
secretAccessKey: "{{ gardener_backup_infrastructure_secret.secretAccessKey | b64decode }}"
{% endif %}
{% endif %}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,12 @@ images:
apiserver: {{ gardener_virtual_api_server_image_name }}:{{ gardener_virtual_api_server_image_tag }}
controllermanager: {{ gardener_virtual_controller_manager_image_name }}:{{ gardener_virtual_controller_manager_image_tag }}

replicas: {{ gardener_virtual_api_replicas }}

apiServer:
hostname: {{ gardener_virtual_api_server_public_dns }}
serviceName: garden-kube-apiserver
adminKubeconfigPort: {{ gardener_virtual_api_server_public_port }}

oidc:
issuerURL: {% if gardener_virtual_api_oidc_issuer_url %}{{ gardener_virtual_api_oidc_issuer_url }}{% endif %}
Expand Down
Loading