<p>Given that I have a 24x7 <code>AKS</code> Cluster on AZURE, for which afaik Kubernetes cannot stop/pause a pod and then resume it standardly,</p>
<ul>
<li><p>with, in my case, a small Container in a Pod, and for that Pod it can be sidelined via <code>--replicas=0</code>,</p>
<ul>
<li><p>then, how can I, on-demand, best kick off a LINIX script packaged in that Pod/Container which may be not running,</p>
<ul>
<li>from an AZURE Web App?</li>
</ul>
</li>
</ul>
</li>
</ul>
<p>I thought using <code>ssh</code> should work, after first upscaling the pod to 1 replica. Is this correct?</p>
<p>I am curious if there are simple <code>http</code> calls in AZURE to do this. I see CLI and Powershell to start/stop AKS cluster, but that is different of course.</p>

thebluephantom
<p>You can interact remotely with AKS by different methods. The key here is to use the control plane API to deploy your kubernetes resource programmatically (<a href="https://kubernetes.io/docs/concepts/overview/kubernetes-api/" rel="nofollow noreferrer">https://kubernetes.io/docs/concepts/overview/kubernetes-api/</a>) .</p>
<p>In order to do that, you should use client libraries that enable that kind of access. Many examples can be found here for different programming languages:
<a href="https://github.com/kubernetes-client" rel="nofollow noreferrer">https://github.com/kubernetes-client</a></p>
<p><code>ssh</code> is not really recommended since that is sort of a god access to the cluster and its usage is not meant for your purpose.</p>
