<p>I want to run pods with <code>runsc</code> as default on my k8s nodes but <code>kube-proxy</code> or other nodes can't be run via <code>runsc</code>. So, I want to automate the process in a way that after the Kubernetes start, every new pod will be run via <code>runsc</code>.</p>

<p>According to the <a href="https://kubernetes.io/docs/concepts/containers/runtime-class/" rel="nofollow noreferrer">official documentation</a>, this can be done with the below steps:</p>
<ul>
<li><p><a href="https://kubernetes.io/docs/concepts/containers/runtime-class/#1-configure-the-cri-implementation-on-nodes" rel="nofollow noreferrer">Configure the CRI implementation on nodes</a></p>
</li>
<li><p><a href="https://kubernetes.io/docs/concepts/containers/runtime-class/#2-create-the-corresponding-runtimeclass-resources" rel="nofollow noreferrer">Create the corresponding RuntimeClass resources</a></p>
</li>
<li><p>Specify a <code>runtimeClassName</code> in the Pod spec.</p>
</li>
</ul>
<p>A step by step guide alongside all necessary details can be found in the linked docs.</p>
<p>Notice that:</p>
<ul>
<li><p>low-level resources, such as <code>nodes</code> and <code>persistentVolumes</code>, are not in any namespace, <code>RuntimeClass</code> is a non-namespaced resource</p>
</li>
<li><p><code>RuntimeClass</code> assumes a homogeneous node configuration across the cluster by default (which means that all nodes are configured the same way with respect to container runtimes). To support heterogeneous node configurations, see <a href="https://kubernetes.io/docs/concepts/containers/runtime-class/#scheduling" rel="nofollow noreferrer">Scheduling</a> below.</p>
</li>
</ul>
