diff --git a/.vuepress/config-sidebar.js b/.vuepress/config-sidebar.js
index cd27ec1..73dd6a7 100644
--- a/.vuepress/config-sidebar.js
+++ b/.vuepress/config-sidebar.js
@@ -43,12 +43,20 @@ module.exports = {
]
},
{
- title: '管理 Kubernetes',
+ title: '安装 Kubernetes 管理工具',
collapsable: false,
children: [
'install-dashboard',
'install-dashboard-offline',
- 'install-dashboard-upgrade',
+ {
+ title: '配置Kuboard',
+ collapsable: true,
+ children: [
+ 'install-dashboard-upgrade',
+ 'install-kuboard-layout',
+ 'install-kuboard-env',
+ ]
+ },
{
title: 'kubectl',
collapsable: true,
diff --git a/install/install-kuboard-env.md b/install/install-kuboard-env.md
index fe3298f..1b54a96 100644
--- a/install/install-kuboard-env.md
+++ b/install/install-kuboard-env.md
@@ -3,10 +3,10 @@ vssueId: 126
description: Kubernetes_Dashboard_是Kubernetes的官方WebUI_本文描述了在K8S集群上安装Kuberentes_Dashboard后_如何修改Kuboard登录页末尾的ICP备案编号_以及其他的一些Kuboard的环境变量
meta:
- name: keywords
- content: Kubernetes Dashboard,安装Kubernetes Dashboard,K8S Dashboard,K8S管理界面
+ content: Kubernetes Dashboard,配置Kuboard环境变量,K8S Dashboard,K8S管理界面
---
-# 安装Kubernetes Dashboard
+# 配置Kuboard环境变量
@@ -86,6 +86,7 @@ Kuboard 用于管理的 Kubernetes 集群上部署的各类资源,如果您想
* 建议您限制可以访问 Kuboard 的 IP 地址白名单;
* 不要泄露 ServiceAccount 的 Token,如需要修改 ServiceAccount 的 Token,请参考 [为名称空间创建管理员用户](/learning/k8s-advanced/sec/kuboard.html) 中,关于在 ServiceAccount 界面上删除 Secret 的部分;
+* 建议使用 [GitLab/GitHub 单点登录](/learning/k8s-advanced/sec/authenticate/install.html)
* 请为 Kuboard 配置 https 证书,配置方式有:
* 在 `http://节点IP:32567/namespace/kube-system/workload/edit/Deployment/kuboard` 界面上互联网入口(Ingress)这一部分开启 https 即可配置;
* 如果您在 Kuboard 前面另外配置了反向代理,请在您自己的反向代理中配置 https 证书;
diff --git a/install/install-kuboard-layout.assets/image-20200301165307517.png b/install/install-kuboard-layout.assets/image-20200301165307517.png
new file mode 100644
index 0000000..0481015
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301165307517.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301175541579.png b/install/install-kuboard-layout.assets/image-20200301175541579.png
new file mode 100644
index 0000000..4b193a5
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301175541579.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301180313243.png b/install/install-kuboard-layout.assets/image-20200301180313243.png
new file mode 100644
index 0000000..1910299
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301180313243.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301181113028.png b/install/install-kuboard-layout.assets/image-20200301181113028.png
new file mode 100644
index 0000000..c6b614f
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301181113028.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301185053459.png b/install/install-kuboard-layout.assets/image-20200301185053459.png
new file mode 100644
index 0000000..276a724
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301185053459.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301192027811.png b/install/install-kuboard-layout.assets/image-20200301192027811.png
new file mode 100644
index 0000000..e67dcd9
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301192027811.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301193155997.png b/install/install-kuboard-layout.assets/image-20200301193155997.png
new file mode 100644
index 0000000..dadaabe
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301193155997.png differ
diff --git a/install/install-kuboard-layout.assets/image-20200301193427725.png b/install/install-kuboard-layout.assets/image-20200301193427725.png
new file mode 100644
index 0000000..e834c5b
Binary files /dev/null and b/install/install-kuboard-layout.assets/image-20200301193427725.png differ
diff --git a/install/install-kuboard-layout.md b/install/install-kuboard-layout.md
new file mode 100644
index 0000000..3268b03
--- /dev/null
+++ b/install/install-kuboard-layout.md
@@ -0,0 +1,136 @@
+---
+vssueId: 126
+description: Kuboard 以微服务分层结构的形式展示名称空间中的所有工作负载
+meta:
+ - name: keywords
+ content: Kuboard 自定义名称空间布局
+---
+
+# 自定义Kuboard名称空间布局
+
+
+
+## 名称空间布局
+
+Kuboard 名称空间界面中,以微服务分层架构的形式对工作负载进行分类展示,默认布局模式如下图所示:
+
+
+
+## 自定义布局
+
+自 Kuboard v1.0.7-beta.5 开始,允许用户自定义名称空间的布局。本章节描述了如何配置自定义布局的参数。
+
+* 在 Kuboard 界面中,导航到 `kube-system` 名称空间;
+
+* 创建 ConfigMap
+
+ > 点击名称空间左侧 **配置** 标题后面的 ***创建*** 按钮,可以创建 ConfigMap。
+
+ 在名称空间 `kube-system` 中创建一个名为 `kuboard-namespace-layout` 的 ConfigMap,并在其中添加一个 Key 为 `kuboard-namespace-layout.yaml` ,Value 为如下 yaml 内容的配置数据条目,如图所示:
+
+ 
+
+ yaml 文件内容为:
+
+ ```yaml
+ version: "0.1"
+
+ layers:
+ frontend:
+ name: 前端
+ color: "blue"
+ backend:
+ name: 后端
+ color: "rgba(0,120,246)"
+ db:
+ name: 数据库
+ color: "#3EAF7C"
+ midware:
+ name: 中间件
+ color: "#003366"
+ direction: vertical-right
+ width: 180
+ ```
+
+ yaml 文件中,各字段的描述如下:
+
+ ::: tip Layer ID
+
+ layers 下每一个字段代表一个分层的 id。例如,此配置文件中定义了 4 个分层:`frontend`、`backend`、`db`、`midware`。对于每个分层,可以配置的参数见下表:
+
+ :::
+
+ | 字段名 | 字段类型 | 必填 | 字段描述 |
+ | --------- | -------- | ---- | ------------------------------------------------------------ |
+ | name | String | 是 | 分层的名称,显示在界面上 |
+ | color | String | 是 | 分层中工作负载对象的主题色,可以使用 rgba 编码、颜色名称颜色编码等 html 支持的形式; |
+ | direction | String | 否 | 如果不填写,则该分层按 yaml 中出现的顺序自上而下显示在中间。如果填写,必须从下面两个取值当中选择:
- `vertical-right`:垂直显示在右侧
- `vertical-left`: 垂直显示在左侧
|
+ | width | Number | 条件 | 如果填写了 `direction` 字段,则此字段为必填;
该字段标识了垂直显示时,该区块的宽度,单位为像素 `px`。 |
+
+
+
+* 挂载 ConfigMap 到 Kuboard 容器
+
+ * 在 `kube-system` 名称空间中,导航到 `kuboard` 工作负载页面;
+
+ * 在 `kuboard` 工作负载页面,点击 ***编辑*** 按钮,进入工作负载编辑页面;
+
+ * 在工作负载编辑页面,增加数据卷
+
+ 为 `kuboard` 增加一个数据卷,字段描述及截图如下:
+
+ | 字段名称 | 字段取值 | 字段描述 |
+ | ------------- | ------------------------------- | ------------------------------------------------------------ |
+ | 数据卷名称 | kuboard-namespace-layout-volume | 数据卷名称,在该工作负载内可用 |
+ | 数据卷类型 | configMap | 选择 configMap 类型的数据卷 |
+ | ConfigMap名称 | kuboard-namespace-layout | 选择前一个步骤中创建的 kuboard-namespace-layout 这个 ConfigMap |
+
+ 
+
+ * 在工作负载编辑页面,挂载配置文件到 `kuboard` 容器
+
+ 仍然在工作负载编辑页面,将 ConfigMap 中的配置内容挂载到 `kuboard` 容器,字段描述及截图如下:
+
+ | 字段名称 | 字段取值 | 字段描述 |
+ | ---------------------- | --------------------------------------------------- | --------------------------------------------- |
+ | 镜像 | eipwork/kuboard:v1.0.7-beta.5 | Kuboard 版本不能低于 v1.0.7-beta.5 |
+ | 挂载点:容器内路径 | /usr/share/nginx/html/kuboard-namespace-layout.yaml | 替换容器中该路径中的配置文件 |
+ | 挂载点:数据卷名称 | kuboard-namespace-layout-volume | 选择前一个步骤中添加的数据卷 |
+ | 挂载点:数据卷内子路径 | kuboard-namespace-layout.yaml | 此字段取值为 configMap 中,对应配置条目的名称 |
+
+ > 上述配置可以将 configMap 中 `kuboard-namspace-layout.yaml` 的内容映射为容器内路径为 `/usr/share/nginx/html/kuboard-namespace-layout.yaml` 的一个文件
+
+ 
+
+ * 保存对 `kuboard` 工作负载的修改
+
+* 刷新 Kuboard 界面
+
+ 刷新 Kuboard 界面后,可以看到,名称空间的布局被调整为如下形式:
+
+ * 省略了左侧的 `监控层`;
+ * 中间三层被调整为 `前端`、`后端`、`数据库`;
+ * 右侧名称仍然为 `中间件` ,但是标识已经从 `cloud` 调整为 `midware`,所以原本在此处的 `服务注册` 工作负载现在显示在 `默认` 分层中。
+
+ 
+
+## 调整工作负载所在分层
+
+如果您在使用 Kuboard 之前,就已经创建了许多的工作负载,然后您安装了 Kuboard,此时,所有的工作负载都是显示在 `默认` 这个分层的。
+
+Kuboard 通过工作负载(Deployment / StatefulSet / DaemonSet 等)的 `k8s.eip.work/layer` 这个标签来识别工作负载应该显示在哪个分层。
+
+如果您想要将工作负载调整到对应的分层,可以按照如下步骤操作:
+
+* 进入工作负载查看页面,如下图所示:
+
+ 
+
+* 点击上图中 ***调整所在分层*** 按钮,将打开编辑标签的界面:
+
+ 编辑 `k8s.eip.work/layer` ,并选择您想要的分层后,点击 ***确定*** 按钮。
+
+ 
+
+* 该工作负载将显示到您所期望的分层当中。
+
diff --git a/support/change-log/change-log-on-the-way.md b/support/change-log/change-log-on-the-way.md
index 191b56d..b397202 100644
--- a/support/change-log/change-log-on-the-way.md
+++ b/support/change-log/change-log-on-the-way.md
@@ -1,23 +1,6 @@
Kuboard v1.0.x 的更新说明
-## v1.0.7-beta.5
-
-**优化**
-
-* KuboardProxy 权限判断,登录用户必须具备 `services/proxy` 或者 `pods/proxy` 的 create 操作权限,才能访问 Kuboard Proxy;
-
-
-**BUG修正**
-
-* 创建工作负载时,layer 不能选择默认;
-* RoleBinding/ClusterRolebinding 对话框 --> 部分情况下不能点击删除按钮;
-
-
-
-
-* 工作负载编辑页 --> 容器 --> 就绪检查 --> 当未填写容器名称时,出现 undefined 的显示
-
------------------
**新特性**
diff --git a/support/change-log/import-bug.yaml b/support/change-log/import-bug.yaml
deleted file mode 100644
index 08db41b..0000000
--- a/support/change-log/import-bug.yaml
+++ /dev/null
@@ -1,79 +0,0 @@
-
----
-apiVersion: apps/v1
-kind: Deployment
-metadata:
- namespace: dev
- name: svc-demo-task
- annotations:
- k8s.eip.work/workload: svc-demo-task
- deployment.kubernetes.io/revision: '7'
- k8s.eip.work/ingress: 'false'
- k8s.eip.work/service: none
- labels:
- boot: demo-task
- k8s.eip.work/layer: svc
- k8s.eip.work/name: svc-demo-task
- project: qjl
-spec:
- selector:
- matchLabels:
- boot: demo-task
- k8s.eip.work/layer: svc
- k8s.eip.work/name: svc-demo-task
- project: qjl
- template:
- metadata:
- labels:
- boot: demo-task
- k8s.eip.work/layer: svc
- k8s.eip.work/name: svc-demo-task
- project: qjl
- spec:
- securityContext:
- seLinuxOptions: {}
- imagePullSecrets: []
- restartPolicy: Always
- initContainers: []
- containers:
- - image: demo/dev-demo-task
- imagePullPolicy: Always
- name: demo-task
- volumeMounts:
- - name: nfs
- readOnly: true
- mountPath: /data/nfs
- resources:
- limits:
- requests:
- env:
- - name: RESTART_
- value: '1582275909'
- readinessProbe:
- httpGet:
- path: /api/ok
- port: 8088
- scheme: HTTP
- initialDelaySeconds: 20
- timeoutSeconds: 1
- periodSeconds: 10
- successThreshold: 1
- failureThreshold: 100
- livenessProbe:
- httpGet:
- path: /api/ok
- port: 8088
- scheme: HTTP
- initialDelaySeconds: 180
- timeoutSeconds: 1
- periodSeconds: 10
- successThreshold: 1
- failureThreshold: 10
- volumes:
- - name: nfs
- nfs:
- server: 192.168.0.144
- path: /data/nfs
- terminationGracePeriodSeconds: 30
- replicas: 1
-
diff --git a/support/change-log/v1.0.x.md b/support/change-log/v1.0.x.md
index 773f7fa..cdc89db 100644
--- a/support/change-log/v1.0.x.md
+++ b/support/change-log/v1.0.x.md
@@ -10,10 +10,30 @@ description: 本文描述了Kuboard_v1.0.x的版本变更说明
了解如何 [升级Kuboard](/install/install-dashboard-upgrade.html)
* eipwork/kuboard:latest 当前对应的版本是 kuboard v1.0.6.3
-* eipwork/kuboard:beta 当前对应的版本是 kuboard v1.0.7-beta.3
+* eipwork/kuboard:beta 当前对应的版本是 kuboard v1.0.7-beta.5
Kuboard v1.0.x 的更新说明
+## v1.0.7-beta.5
+
+**发布日期**
+
+2020年3月1日
+
+**优化**
+
+* KuboardProxy 权限判断,登录用户必须具备 `services/proxy` 或者 `pods/proxy` 的 create 操作权限,才能访问对应的 Kuboard Proxy;
+* 工作负载页 --> 修改工作负载的标签
+* [自定义 Kuboard namespace 布局](/install/install-kuboard-layout.html)
+
+**BUG修正**
+
+* 创建工作负载时,layer 不能选择默认;
+* RoleBinding/ClusterRolebinding 对话框 --> 部分情况下不能点击删除按钮;
+* 集群概览页 --> 计算资源区最大化时的布局问题
+* 工作负载编辑页 --> 容器 --> 就绪检查 --> 当未填写容器名称时,出现 undefined 的显示
+
+
## v1.0.7-beta.4
**发布日期**