You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/machine-config-node-disruption-example.adoc
+22-24Lines changed: 22 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,7 +73,27 @@ status:
73
73
74
74
The default node disruption policy does not contain a policy for changes to the `/etc/containers/registries.conf.d` file. This is because both {product-title} and {op-system-base-full} use the `registries.conf.d` file to specify aliases for image short names. It is recommended that you always pull an image by its fully-qualified name. This is particularly important with public registries, because the image might not deploy if the public registry requires authentication. You can create a user-defined policy to use with the `/etc/containers/registries.conf.d` file, if you need to use image short names.
75
75
76
-
In the following example, when changes are made to the SSH keys, the MCO drains the cluster nodes, reloads the `crio.service`, reloads the systemd configuration, and restarts the `crio-service`.
76
+
In the following example, when changes are made to the `registries.conf.d` file, the MCO restarts the `crio-service`.
77
+
78
+
.Example node disruption policy for a change to the `registries.conf` file
79
+
[source,yaml]
80
+
----
81
+
apiVersion: operator.openshift.io/v1
82
+
kind: MachineConfiguration
83
+
metadata:
84
+
name: cluster
85
+
namespace: openshift-machine-config-operator
86
+
spec:
87
+
nodeDisruptionPolicy:
88
+
files:
89
+
- path: /etc/containers/registries.conf.d
90
+
actions:
91
+
- type: Restart
92
+
- restart:
93
+
serviceName: crio.service
94
+
----
95
+
96
+
In the following example, when changes are made to the SSH keys, the MCO reloads the systemd configuration, and restarts the `crio-service`.
77
97
78
98
.Example node disruption policy for an SSH key change
79
99
[source,yaml]
@@ -87,14 +107,10 @@ spec:
87
107
nodeDisruptionPolicy:
88
108
sshkey:
89
109
actions:
90
-
- type: Drain
91
-
- reload:
92
-
serviceName: crio.service
93
-
type: Reload
94
110
- type: DaemonReload
95
111
- restart:
96
112
serviceName: crio.service
97
-
type: Restart
113
+
type: Restart
98
114
# ...
99
115
----
100
116
@@ -145,21 +161,3 @@ spec:
145
161
restart:
146
162
serviceName: crio.service
147
163
----
148
-
149
-
In the following example, when changes are made to the `registries.conf` file, such as by editing an `ImageContentSourcePolicy` (ICSP) object, the MCO does not drain or reboot the nodes and applies the changes with no further action.
150
-
151
-
.Example node disruption policy for a registries.conf file change
Copy file name to clipboardExpand all lines: snippets/machine-config-node-disruption-actions.adoc
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@ When you make any of these changes, the node disruption policy determines which
11
11
* *Reload*: For services, the MCO reloads the specified services without restarting the service.
12
12
* *Restart*: For services, the MCO fully restarts the specified services.
13
13
* *DaemonReload*: The MCO reloads the systemd manager configuration.
14
-
* *Special*: This is an internal MCO-only action and cannot be set by the user.
14
+
* *Special*: This is an internal MCO-only action that is set by default for changes to the `/etc/containers/registries.conf` file. When this action is set, the MCO determines if a node cordon and drain is required, based on the changed content in the `registries.conf` file. You can override this default. However, it is not recommended to override this setting. You cannot set this action for another path or service.
0 commit comments