Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kubespray
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mirror
Kubespray
Commits
8031c6c1
Commit
8031c6c1
authored
5 years ago
by
andreyshestakov
Committed by
Kubernetes Prow Robot
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Update template for dashboard to support v2.x (#5187)
Secrets and ConfigMap should be created before dashboard pod run.
parent
9d8fc8ca
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
roles/kubernetes-apps/ansible/templates/dashboard.yml.j2
+35
-10
35 additions, 10 deletions
roles/kubernetes-apps/ansible/templates/dashboard.yml.j2
with
35 additions
and
10 deletions
roles/kubernetes-apps/ansible/templates/dashboard.yml.j2
+
35
−
10
View file @
8031c6c1
...
...
@@ -17,7 +17,8 @@
#
# Example usage: kubectl create -f <this_file>
# ------------------- Dashboard Secret ------------------- #
---
# ------------------- Dashboard Secrets ------------------- #
apiVersion: v1
kind: Secret
...
...
@@ -28,6 +29,38 @@ metadata:
namespace: kube-system
type: Opaque
---
apiVersion: v1
kind: Secret
metadata:
labels:
k8s-app: kubernetes-dashboard
name: kubernetes-dashboard-csrf
namespace: kube-system
type: Opaque
data:
csrf: ""
---
apiVersion: v1
kind: Secret
metadata:
labels:
k8s-app: kubernetes-dashboard
name: kubernetes-dashboard-key-holder
namespace: kube-system
type: Opaque
---
# ------------------- Dashboard ConfigMap ------------------- #
kind: ConfigMap
apiVersion: v1
metadata:
labels:
k8s-app: kubernetes-dashboard
name: kubernetes-dashboard-settings
namespace: kube-system
---
# ------------------- Dashboard Service Account ------------------- #
...
...
@@ -48,18 +81,10 @@ metadata:
name: kubernetes-dashboard-minimal
namespace: kube-system
rules:
# Allow Dashboard to create 'kubernetes-dashboard-key-holder' secret.
- apiGroups: [""]
resources: ["secrets"]
verbs: ["create"]
# Allow Dashboard to create 'kubernetes-dashboard-settings' config map.
- apiGroups: [""]
resources: ["configmaps"]
verbs: ["create"]
# Allow Dashboard to get, update and delete Dashboard exclusive secrets.
- apiGroups: [""]
resources: ["secrets"]
resourceNames: ["kubernetes-dashboard-key-holder", "kubernetes-dashboard-certs"]
resourceNames: ["kubernetes-dashboard-key-holder", "kubernetes-dashboard-certs"
, "kubernetes-dashboard-csrf"
]
verbs: ["get", "update", "delete"]
# Allow Dashboard to get and update 'kubernetes-dashboard-settings' config map.
- apiGroups: [""]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment