<p>I got to know that the &quot;krew&quot; is the famous and fancy kubernetes plugin.</p>
<p>So I want to install the &quot;krew&quot; in my clusters.</p>
<p>But because of some reasons, my clusters must be disconnected to public internet.</p>
<p>I installed the k8s in my clusters with offline. (kubespray)</p>
<p>I pushed the necessary binary files into my cluster through FTP.</p>
<p>In this condition, how can I install &quot;krew&quot;?</p>
<p>I tried to transmit the &quot;krew&quot; binary file to my cluster, but after installment the &quot;krew&quot; binary looked for some files from public github.</p>
<p>Since my cluster cannot reach the public internet, the &quot;krew&quot; failed to find some files and the installment also failed.</p>
<p>Can you help me?</p>

JAESANGPARK
<p>Not sure what you would achieve by having <code>krew</code> installed in an offline environment. <code>krew</code> need the internet to download the various plugins from their source over the internet.</p>
<p>Although, You &quot;may&quot; not need to install <code>krew</code> at all. You can manually check the plugin list at this <a href="https://krew.sigs.k8s.io/plugins/" rel="nofollow noreferrer">link</a>. Once you decide which plugin you want to install, download the binary/executable and place it under your <code>$PATH</code> directory. If you name the executable with the <code>kubectl-</code> prefix, kubectl would consider it as a plugin, if the file is placed in <code>$PATH</code>.</p>
<p>Then you may run it as any of the following way:</p>
<ol>
<li><code>kubectl &lt;plugin-name&gt;</code></li>
<li><code>./&lt;plugin-downloaded-executable&gt;</code></li>
</ol>
<p>An example of how to make a custom plugin is provided here <a href="https://kubernetes.io/docs/tasks/extend-kubectl/kubectl-plugins/#writing-kubectl-plugins" rel="nofollow noreferrer">link</a>. This can be used to replace any downloaded plugin.</p>
<p>Note that, this method worked for me for most of the plugins, but not guaranteed to work on all as testing for all the plugins is not possible.</p>
