Skip to content

Commit c625dbf

Browse files
committed
Update README.md
1 parent 7a2dbe8 commit c625dbf

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

README.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ should be reconciled. Supports conditional resources in runtime, ordering of res
2323
The project introduces two Kubernetes custom resources `Glue` and `GlueOperator`.
2424
You can use `GlueOperator` to define your own operator.
2525
Let's take a look at an example, where we define an operator for WebPage custom resource, that represents a static website served from the Cluster. (You can see the
26-
[full example here](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/webpage)):
26+
[full example here](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/webpage) ):
2727

2828
```yaml
2929

@@ -45,7 +45,7 @@ spec:
4545
```
4646
4747
To create an operator (or more precisely the controller part) with `resource-glue-operator` we have first apply
48-
the {CRD for WebPage](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/webpage/webpage.crd.yml).
48+
the [CRD for WebPage](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/webpage/webpage.crd.yml).
4949
To define how the `WebPage` should be reconciled, thus what resources should be created for
5050
a `WebPage`, we prepare a `GlueOperator`:
5151

@@ -120,7 +120,7 @@ resources are applied, however, there are certain cases when this is needed also
120120
The following example shows how to deploy a [dynamic admission controller](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/) that mutates
121121
all the `Pods`, adding annotation on them. Note that this is a tricky situation since the endpoint for the `MutatingWebhookConfiguration` is also a `Pod`, thus it should be
122122
first up and running before the configuration is applied, otherwise, the mutation webhook will block the changes on the pods, which would render the cluster unable to manage `Pods'
123-
(irrelevant details are omitted, see the full version [here][https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/mutation/mutation.glue.yaml]):
123+
(irrelevant details are omitted, see the full version [here](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/resources/sample/mutation/mutation.glue.yaml)):
124124

125125
```yaml
126126
apiVersion: io.csviri.operator.resourceglue/v1beta1
@@ -137,7 +137,7 @@ spec:
137137
name: pod-mutating-hook
138138
spec:
139139
# spec omitted
140-
- name: deployment # webhook endpoint
140+
- name: deployment # webhook web-service endpoint
141141
readyPostCondition:
142142
type: ReadyCondition # ready post conditions determine when a Deployment is considered "ready", thus up and running.
143143
resource:
@@ -158,8 +158,10 @@ spec:
158158
protocol: TCP
159159
160160
- name: mutation_hook_config
161-
# dependsOn relation means, that the resource will be reconciled only if all the listed resources are already reconciled and ready (if ready post-condition is present).
162-
# This resource will be applied, after the service and deployment are applied, and the deployment is ready, thus all the pods are started up and ready.
161+
# dependsOn relation means, that the resource will be reconciled only if all
162+
# the listed resources are already reconciled and ready (if ready post-condition is present).
163+
# This resource will be applied after the service and deployment are applied,
164+
# and the deployment is ready, thus all the pods are started up and ready.
163165
dependsOn:
164166
- deployment
165167
- service
@@ -190,5 +192,5 @@ spec:
190192
- pods
191193
```
192194

193-
195+
See the full E2E test [here](https://github.com/csviri/resource-workflow-operator/blob/main/src/test/java/io/csviri/operator/resourceglue/sample/mutation/MutationWebhookDeploymentE2E.java).
194196

0 commit comments

Comments
 (0)