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

kube-1.28 to alpha #7307

Merged
merged 15 commits into from
Apr 12, 2024
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
4 changes: 3 additions & 1 deletion cluster/config-defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -923,10 +923,12 @@ stackset_ingress_source_switch_ttl: "5m"
# enable/disable inline configmap support for stackset
stackset_inline_configmap_support_enabled: "false"

# enable/disable platformCredentialsSet support for stackset
stackset_pcs_support_enabled: "false"

# Enable/Disable profiling for Kubernetes components
enable_control_plane_profiling: "false"

okta_auth_enabled: "true"
okta_auth_issuer_url: ""
okta_auth_client_id: "kubernetes.cluster.{{.Cluster.Alias}}"

Expand Down
4 changes: 0 additions & 4 deletions cluster/manifests/deletions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,6 @@ post_apply:
- name: spot-node-rescheduler
kind: ClusterRoleBinding
{{ end }}
{{- if ne .Cluster.ConfigItems.okta_auth_enabled "true" }}
- name: cluster-admin-okta
kind: ClusterRoleBinding
{{- end }}

{{ if ne .Cluster.ConfigItems.skipper_ingress_canary_enabled "true" }}
- name: skipper-ingress-canary
Expand Down
2 changes: 0 additions & 2 deletions cluster/manifests/roles/cluster-admin-binding.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{{- if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
Expand All @@ -11,4 +10,3 @@ subjects:
- apiGroup: rbac.authorization.k8s.io
kind: Group
name: okta:common/administrator
{{- end }}
2 changes: 0 additions & 2 deletions cluster/manifests/roles/collaborator-roles.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ subjects:
- kind: Group
name: CollaboratorEmergency
apiGroup: rbac.authorization.k8s.io
{{- if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
- kind: Group
name: "okta:common/collaborator"
apiGroup: rbac.authorization.k8s.io
{{- end }}
2 changes: 0 additions & 2 deletions cluster/manifests/roles/poweruser-binding.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,9 @@ subjects:
- kind: Group
name: Emergency
apiGroup: rbac.authorization.k8s.io
{{- if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
- kind: Group
name: "okta:common/engineer"
apiGroup: rbac.authorization.k8s.io
- kind: Group
name: "okta:common/collaborator"
apiGroup: rbac.authorization.k8s.io
{{- end }}
6 changes: 0 additions & 6 deletions cluster/manifests/roles/readonly-binding.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ subjects:
- kind: Group
name: ReadOnly
apiGroup: rbac.authorization.k8s.io
# {{ if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
- kind: Group
name: "okta:common/engineer"
apiGroup: rbac.authorization.k8s.io
Expand All @@ -20,7 +19,6 @@ subjects:
- kind: Group
name: "okta:common/read-only"
apiGroup: rbac.authorization.k8s.io
# {{ end }}
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
Expand All @@ -35,7 +33,6 @@ subjects:
- kind: Group
name: ReadOnly
apiGroup: rbac.authorization.k8s.io
# {{ if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
- kind: Group
name: "okta:common/engineer"
apiGroup: rbac.authorization.k8s.io
Expand All @@ -45,7 +42,6 @@ subjects:
- kind: Group
name: "okta:common/read-only"
apiGroup: rbac.authorization.k8s.io
# {{ end }}
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
Expand All @@ -60,7 +56,6 @@ subjects:
- kind: Group
name: ReadOnly
apiGroup: rbac.authorization.k8s.io
# {{ if eq .Cluster.ConfigItems.okta_auth_enabled "true" }}
- kind: Group
name: "okta:common/engineer"
apiGroup: rbac.authorization.k8s.io
Expand All @@ -70,4 +65,3 @@ subjects:
- kind: Group
name: "okta:common/read-only"
apiGroup: rbac.authorization.k8s.io
# {{ end }}
20 changes: 20 additions & 0 deletions cluster/manifests/stackset-controller/01-stack-crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,26 @@ spec:
description: Name of the ConfigMap
type: string
type: object
{{ end }}
{{- if eq .Cluster.ConfigItems.stackset_pcs_support_enabled "true" }}
platformCredentialsSet:
description: PlatformCredentialsSet to be created and owned
by Stack
properties:
name:
type: string
tokens:
additionalProperties:
properties:
privileges:
items:
type: string
type: array
required:
- privileges
type: object
type: object
type: object
{{ end }}
configMapRef:
description: ConfigMap to be owned by Stack
Expand Down
20 changes: 20 additions & 0 deletions cluster/manifests/stackset-controller/01-stackset-crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,26 @@ spec:
description: Name of the ConfigMap
type: string
type: object
{{ end }}
{{- if eq .Cluster.ConfigItems.stackset_pcs_support_enabled "true" }}
platformCredentialsSet:
description: PlatformCredentialsSet to be created and owned
by Stack
properties:
name:
type: string
tokens:
additionalProperties:
properties:
privileges:
items:
type: string
type: array
required:
- privileges
type: object
type: object
type: object
{{ end }}
configMapRef:
description: ConfigMap to be owned by Stack
Expand Down
12 changes: 6 additions & 6 deletions cluster/manifests/z-karpenter/04-clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ metadata:
component: karpenter
rules:
# Read
- apiGroups: [ "karpenter.k8s.aws" ]
resources: [ "ec2nodeclasses" ]
verbs: [ "get", "list", "watch" ]
- apiGroups: ["karpenter.k8s.aws"]
resources: ["ec2nodeclasses"]
verbs: ["get", "list", "watch"]
# Write
- apiGroups: [ "karpenter.k8s.aws" ]
resources: [ "ec2nodeclasses", "ec2nodeclasses/status" ]
verbs: [ "patch", "update" ]
- apiGroups: ["karpenter.k8s.aws"]
resources: ["ec2nodeclasses", "ec2nodeclasses/status"]
verbs: ["patch", "update"]
---
# Source: karpenter/templates/04-clusterrole.yaml
apiVersion: rbac.authorization.k8s.io/v1
Expand Down
2 changes: 1 addition & 1 deletion cluster/manifests/z-karpenter/05-clusterrole-core.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ rules:
verbs: ["create", "patch"]
- apiGroups: [""]
resources: ["nodes"]
verbs: ["create", "patch", "delete"]
verbs: ["patch", "delete"]
- apiGroups: [""]
resources: ["pods/eviction"]
verbs: ["create"]
Expand Down
Loading