Skip to content

Commit 11b95f7

Browse files
committed
use pre-defined identity in the VR example for easier deployment
On-behalf-of: @SAP [email protected] Signed-off-by: Robert Vasek <[email protected]>
1 parent ece7af0 commit 11b95f7

File tree

4 files changed

+20
-8
lines changed

4 files changed

+20
-8
lines changed

config/examples/virtualresources/README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# VirtualResources Example
22

3-
This example shows usage of VirtualResources, together with CachedResources.
4-
The goal of VirtualResources is to distribute static, read-only resources to multiple clusters
3+
This example shows usage of virtual resources, together with CachedResources.
4+
The goal of CachedResources is to distribute static, read-only resources to multiple clusters
55
in a scalable way.
66

77
## Setup
@@ -19,15 +19,16 @@ in a scalable way.
1919
kubectl ws create provider --enter
2020

2121
kubectl create -f config/examples/virtualresources/crd-instances.yaml
22-
# this this to work we always require apiresource schema to be present
22+
# for this to work we always require apiresource schema to be present
2323
kubectl create -f config/examples/virtualresources/apiresourceschema-instances.yaml
2424
kubectl create -f config/examples/virtualresources/instances.yaml
2525

26-
# create caching for the resources
26+
# create caching for the resources with a pre-made CachedResources identity
27+
kubectl create -f config/examples/virtualresources/cached-resource-identity.yaml
2728
kubectl create -f config/examples/virtualresources/cached-resource-instances.yaml
2829
```
2930

30-
3. Create a an APIResourceSchema for actual virtual machines to be distributed,
31+
3. Create an APIResourceSchema for actual virtual machines to be distributed,
3132
which will be using instance types.
3233

3334
```bash
@@ -52,4 +53,4 @@ in a scalable way.
5253

5354
```bash
5455
kubectl get instances.machines.svm.io
55-
```
56+
```

config/examples/virtualresources/apiexport.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ spec:
1313
apiGroup: cache.kcp.io
1414
kind: CachedResourceEndpointSlice
1515
name: instances
16-
identityHash: 2857921554ab76ec50f25bf083b7aeb4f7808cd169fd2945b007429f426614ec
16+
identityHash: 676a1a997f7507fdfcfd1fcf35920efdff1297cd215cad4f486220c30a5c7090
1717
- name: virtualmachines
1818
group: machines.svm.io
1919
schema: today.virtualmachines.machines.svm.io
2020
storage:
21-
crd: {}
21+
crd: {}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: v1
2+
kind: Secret
3+
metadata:
4+
name: instances-cr-identity
5+
namespace: default
6+
stringData:
7+
key: instances-cr-identity-123

config/examples/virtualresources/cached-resource-instances.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,7 @@ spec:
99
labelSelector:
1010
matchLabels:
1111
app.kubernetes.io/part-of: instances
12+
identity:
13+
secretRef:
14+
name: instances-cr-identity
15+
namespace: default

0 commit comments

Comments
 (0)