Skip to content
This repository was archived by the owner on Mar 1, 2023. It is now read-only.

Commit 7e51464

Browse files
authored
Merge pull request #30 from vmware-tanzu-labs/develop
v1.4.2
2 parents dec08d9 + 9e1cf42 commit 7e51464

File tree

9 files changed

+68
-51
lines changed

9 files changed

+68
-51
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# image build vars
77
IMAGE ?= projects.registry.vmware.com/rpk/rpk
8-
IMAGE_VERSION ?= v1.4.1
8+
IMAGE_VERSION ?= v1.4.2
99
IMAGE_BASE ?= projects.registry.vmware.com/rpk/rpk-base
1010
IMAGE_BASE_VERSION ?= v1.4.0
1111

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -59,28 +59,28 @@ paths seen and expect our approaches to **evolve over time**.
5959

6060
Kubernetes user needs fit on a spectrum, typically landing in
6161
one of 3 personas. Each persona envisions a slightly different path to
62-
production. We often identify these personas as bronze, silver, and gold.
62+
production. We often identify these personas as foundational, advanced, and opinionated.
6363

64-
![Bronze-Silver-Gold](docs/images/bronze-silver-gold.png)
64+
![Personas](docs/images/personas.png)
6565

66-
* **Bronze**: I want an enterprise-grade Kubernetes distribution. This persona
66+
* **Foundational**: I want an enterprise-grade Kubernetes distribution. This persona
6767
is largely interested in having the foundation poured but is not yet ready to
68-
build the house. In our experience, the path to production with bronze is rarely
69-
achieved without moving on to a silver or gold aspiration. However, the bronze
70-
intention may be right for the customer at the time, especially when their
68+
build the house. In our experience, the path to production with the foundational persona is rarely
69+
achieved without moving on to one of the other below aspirations. However, the intent
70+
behind the implementation selection may be right for the customer at the time, especially when their
7171
production intentions are largely non-determined.
7272

73-
* **Silver**: I want to **create** a viable place to run applications in production
73+
* **Advanced**: I want to **create** a viable place to run applications in production
7474
with Kubernetes as the foundation. This persona not only wants to pour the
7575
foundation, but also help design, build, and operationalize an application
7676
platform on top - ensuring they end up with a habitable place for
7777
applications to live (i.e., running in production).
7878

79-
* **Gold**: I want to **deploy** a fully-baked application platform that is
80-
ready for production, with Kubernetes as the foundation. This persona wants to
79+
* **Opinionated**: I want to **deploy** a fully-baked application platform that is
80+
ready for production. This persona wants to
8181
adopt hardened opinions of a vendor - similar to an established housing developer,
8282
they can have a quality, habitable, home built. This lowers the effort seen in
83-
the Silver persona around architecting / building, although some extension may
83+
the Advanced persona around architecting / building, although some extension may
8484
be involved.
8585

8686
## Is RPK a VMware Product?

docs/images/bronze-silver-gold.png

-145 KB
Binary file not shown.

docs/images/personas.png

214 KB
Loading
Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,2 @@
11
# Copyright 2006-2021 VMware, Inc.
22
# SPDX-License-Identifier: MIT
3-
---
4-
#
5-
# DNS
6-
#
7-
- name: "get the ingress ip"
8-
import_role:
9-
name: "common/ingress-ip"
10-
11-
- name: "ensure dns resolvability for identity module"
12-
include_role:
13-
name: "common/etc-hosts"
14-
vars:
15-
ip: "{{ ingress_ip }}"
16-
fqdn: "{{ item }}"
17-
with_items:
18-
- "{{ tanzu_identity.dex.dns }}"
19-
- "{{ tanzu_identity.gangway.dns }}"
20-
21-
#
22-
# RETRIEVE CLUSTER INFO
23-
#
24-
- name: "retrieve cluster info"
25-
import_role:
26-
name: "common/cluster-info"
27-
when: tanzu_apiserver_url is not defined

roles/components/core/identity/tasks/main.yaml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,31 @@
1818
namespace_template_file: "tanzu-namespace.yaml.j2"
1919
namespace_file: "{{ tanzu_identity.staging_dir }}/tanzu-namespace.yaml"
2020

21+
#
22+
# DNS
23+
#
24+
- name: "get the ingress ip"
25+
import_role:
26+
name: "common/ingress-ip"
27+
28+
- name: "ensure dns resolvability for identity module"
29+
include_role:
30+
name: "common/etc-hosts"
31+
vars:
32+
ip: "{{ ingress_ip }}"
33+
fqdn: "{{ item }}"
34+
with_items:
35+
- "{{ tanzu_identity.dex.dns }}"
36+
- "{{ tanzu_identity.gangway.dns }}"
37+
38+
#
39+
# RETRIEVE CLUSTER INFO
40+
#
41+
- name: "retrieve cluster info"
42+
import_role:
43+
name: "common/cluster-info"
44+
when: tanzu_apiserver_url is not defined
45+
2146
#
2247
# LDAP
2348
#
@@ -29,6 +54,14 @@
2954
manifest_template: "psp-ldap.yaml.j2"
3055
manifest_staging_dir: "{{ tanzu_identity.staging_dir }}"
3156

57+
- name: "ensure ldap rbac exists"
58+
import_role:
59+
name: "common/manifest-file-with-wait"
60+
vars:
61+
manifest_description: "ldap rbac"
62+
manifest_template: "rbac-ldap.yaml.j2"
63+
manifest_staging_dir: "{{ tanzu_identity.staging_dir }}"
64+
3265
- name: "ensure ldap config exists"
3366
import_role:
3467
name: "common/manifest-file-with-wait"

roles/components/core/identity/templates/config-ldap.yaml.j2

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,6 @@
11
# Copyright 2006-2021 VMware, Inc.
22
# SPDX-License-Identifier: MIT
33
---
4-
apiVersion: rbac.authorization.k8s.io/v1beta1
5-
kind: ClusterRoleBinding
6-
metadata:
7-
name: tanzu-admin
8-
namespace: {{ tanzu_identity.namespace }}
9-
roleRef:
10-
apiGroup: rbac.authorization.k8s.io
11-
kind: ClusterRole
12-
name: cluster-admin
13-
subjects:
14-
- kind: User
15-
name: {{ tanzu_identity.ldap.admin_user }}
16-
---
174
apiVersion: v1
185
kind: ConfigMap
196
metadata:

roles/components/core/identity/templates/job-kube-apiserver.yaml.j2

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ metadata:
77
name: kube-apiserver-config
88
namespace: "{{ tanzu_identity.namespace }}"
99
data:
10+
UPDATE_K8S_CA: "{{ ((tanzu_security.actions.update_k8s_ca | bool) and (('letsencrypt-stage' in tanzu_security.tls_providers) or ('ca' in tanzu_security.tls_providers) or ('wildcard' in tanzu_security.tls_providers))) | string | lower }}"
1011
kube-apiserver-config-values.yaml: |
1112
#@data/values
1213
---
13-
UPDATE_K8S_CA: "{{ ((tanzu_security.actions.update_k8s_ca | bool) and (('letsencrypt-stage' in tanzu_security.tls_providers) or ('ca' in tanzu_security.tls_providers) or ('wildcard' in tanzu_security.tls_providers))) | string | lower }}"
14+
UPDATE_K8S_CA: ""
1415
kube-apiserver-config-overlay.yaml: |
1516
#@ load("@ytt:overlay", "overlay")
1617
#@ load("@ytt:data", "data")
@@ -66,13 +67,19 @@ spec:
6667
containers:
6768
- image: gerritk/ytt:v0.30.0
6869
name: kube-apiserver-config
70+
env:
71+
- name: UPDATE_K8S_CA
72+
valueFrom:
73+
configMapKeyRef:
74+
name: kube-apiserver-config
75+
key: UPDATE_K8S_CA
6976
command:
7077
- "/bin/sh"
7178
args:
7279
- "-c"
7380
- |
7481
cat /etc/kubernetes/manifests/kube-apiserver.yaml > /etc/kubernetes/backup/kube-apiserver.yaml.orig
75-
/usr/bin/ytt -f /etc/kubernetes/manifests/kube-apiserver.yaml -f /etc/kubernetes/kube-apiserver-config-values.yaml -f /etc/kubernetes/kube-apiserver-config-overlay.yaml > /etc/kubernetes/backup/kube-apiserver.yaml.new
82+
/usr/bin/ytt --data-values-env UPDATE_K8S_CA -f /etc/kubernetes/manifests/kube-apiserver.yaml -f /etc/kubernetes/kube-apiserver-config-values.yaml -f /etc/kubernetes/kube-apiserver-config-overlay.yaml > /etc/kubernetes/backup/kube-apiserver.yaml.new
7683
if [ "$(cat /etc/kubernetes/backup/kube-apiserver.yaml.new)" != "" ]; then
7784
cat /etc/kubernetes/backup/kube-apiserver.yaml.new > /etc/kubernetes/manifests/kube-apiserver.yaml
7885
else
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Copyright 2006-2021 VMware, Inc.
2+
# SPDX-License-Identifier: MIT
3+
---
4+
apiVersion: rbac.authorization.k8s.io/v1beta1
5+
kind: ClusterRoleBinding
6+
metadata:
7+
name: tanzu-admin
8+
namespace: {{ tanzu_identity.namespace }}
9+
roleRef:
10+
apiGroup: rbac.authorization.k8s.io
11+
kind: ClusterRole
12+
name: cluster-admin
13+
subjects:
14+
- kind: User
15+
name: {{ tanzu_identity.ldap.admin_user }}

0 commit comments

Comments
 (0)