Skip to content

Commit 3870b77

Browse files
update examples for Subscription config features
added examples for Tolerations and Resources spec in Subscription config. Signed-off-by: Umanga Chapagain <[email protected]>
1 parent f71501a commit 3870b77

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed

doc/design/subscription-config.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,3 +84,52 @@ spec:
8484
- mountPath: /config
8585
name: config-volume
8686
```
87+
88+
### Tolerations
89+
90+
The `tolerations` field defines a list of [Tolerations](https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/) for the Pod created by OLM.
91+
92+
> Note: Tolerations defined here will be appended to existing Tolerations, if not already present.
93+
94+
#### Example
95+
96+
Inject toleration to tolerate all taints.
97+
98+
```
99+
kind: Subscription
100+
metadata:
101+
name: my-operator
102+
spec:
103+
package: etcd
104+
channel: alpha
105+
config:
106+
tolerations:
107+
- operator: "Exists"
108+
```
109+
110+
### Resources
111+
112+
The `resources` field defines [Resource Constraints](https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#resource-requests-and-limits-of-pod-and-container) for all the containers in the Pod created by OLM.
113+
114+
> Note: Resource Constraints defined here will overwrite existing resource constraints.
115+
116+
#### Example
117+
118+
Inject a request of 0.25 cpu and 64 MiB of memory, and a limit of 0.5 cpu and 128MiB of memory in each container.
119+
120+
```
121+
kind: Subscription
122+
metadata:
123+
name: my-operator
124+
spec:
125+
package: etcd
126+
channel: alpha
127+
config:
128+
resources:
129+
requests:
130+
memory: "64Mi"
131+
cpu: "250m"
132+
limits:
133+
memory: "128Mi"
134+
cpu: "500m"
135+
```

0 commit comments

Comments
 (0)