Skip to content

Commit bf051c8

Browse files
committed
Extend existing sample files
On-behalf-of: SAP <[email protected]> Signed-off-by: Marvin Beckers <[email protected]>
1 parent 5ef9254 commit bf051c8

File tree

6 files changed

+78
-6
lines changed

6 files changed

+78
-6
lines changed

config/samples/v1alpha1_frontproxy.yaml

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,27 @@ metadata:
66
app.kubernetes.io/managed-by: kustomize
77
name: frontproxy-sample
88
spec:
9+
image:
10+
tag: eb60348a
11+
auth:
12+
# don't drop requests from administrative groups.
13+
# this shouldn't be enabled in production, but makes testing easier.
14+
dropGroups: [""]
915
rootShard:
1016
ref:
1117
name: shard-sample
12-
externalHostname: kcp.example.com
18+
serviceTemplate:
19+
spec:
20+
# hard code a specific cluster IP, e.g. for a kind setup.
21+
clusterIP: 10.96.100.100
22+
certificateTemplates:
23+
server:
24+
spec:
25+
dnsNames:
26+
# add localhost to the certificate.
27+
- localhost
28+
ipAddresses:
29+
# add localhost IPs to the server certificate.
30+
# this allows easy port-forward access.
31+
- 127.0.0.1
32+
- 127.0.0.2

config/samples/v1alpha1_kubeconfig.yaml renamed to config/samples/v1alpha1_kubeconfig_frontproxy.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ metadata:
44
labels:
55
app.kubernetes.io/name: kcp-operator
66
app.kubernetes.io/managed-by: kustomize
7-
name: kubeconfig-sample
7+
name: kubeconfig-kcp-admin
88
spec:
9-
username: user@kcp.io
9+
username: kcp-admin
1010
groups:
11-
- kcp-users
11+
- system:kcp:admin
1212
validity: 8766h
1313
secretRef:
1414
name: sample-kubeconfig
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: operator.kcp.io/v1alpha1
2+
kind: Kubeconfig
3+
metadata:
4+
labels:
5+
app.kubernetes.io/name: kcp-operator
6+
app.kubernetes.io/managed-by: kustomize
7+
name: kubeconfig-shard-root-admin
8+
spec:
9+
username: shard-root-admin
10+
groups:
11+
- system:kcp:admin
12+
validity: 8766h
13+
secretRef:
14+
name: kubeconfig-shard-root-admin
15+
target:
16+
rootShardRef:
17+
name: shard-sample
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: operator.kcp.io/v1alpha1
2+
kind: Kubeconfig
3+
metadata:
4+
labels:
5+
app.kubernetes.io/name: kcp-operator
6+
app.kubernetes.io/managed-by: kustomize
7+
name: kubeconfig-shard-secondary-admin
8+
spec:
9+
username: shard-root-admin
10+
groups:
11+
- system:kcp:admin
12+
validity: 8766h
13+
secretRef:
14+
name: kubeconfig-shard-secondary-admin
15+
target:
16+
shardRef:
17+
name: secondary-shard

config/samples/v1alpha1_rootshard.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ metadata:
66
app.kubernetes.io/managed-by: kustomize
77
name: shard-sample
88
spec:
9+
image:
10+
tag: eb60348a
911
external:
1012
hostname: example.operator.kcp.io
1113
port: 6443
@@ -20,3 +22,12 @@ spec:
2022
etcd:
2123
endpoints:
2224
- http://etcd.default.svc.cluster.local:2379
25+
deploymentTemplate:
26+
spec:
27+
template:
28+
spec:
29+
hostAliases:
30+
# add a hardcoded DNS override to the same IP as in v1alpha1_frontproxy.yaml.
31+
- ip: "10.96.100.100"
32+
hostnames:
33+
- "example.operator.kcp.io"

config/samples/v1alpha1_shard.yaml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@ metadata:
44
labels:
55
app.kubernetes.io/name: kcp-operator
66
app.kubernetes.io/managed-by: kustomize
7-
name: shard-sample
7+
name: secondary-shard
88
spec:
9-
# TODO(user): Add fields here
9+
image:
10+
tag: eb60348a
11+
etcd:
12+
endpoints:
13+
- http://etcd-shard.default.svc.cluster.local:2379
14+
rootShard:
15+
ref:
16+
name: shard-sample

0 commit comments

Comments
 (0)