<p>I am trying to set up kubemq in my cluster, and this is the command the shown in their README</p>
<pre class="lang-bash prettyprint-override"><code>kubectl apply -f https://deploy.kubemq.io/community
</code></pre>
<p>There are a lot of empty field in that yaml and I want to customize it. How can I override an external yaml file applied by <code>kubectl</code>?</p>

John Winston
<p>In the Kubernetes world, It's generally an unsafe idea to run a command like the below unless you trust the URL:</p>
<pre><code>kubectl apply -f &lt;some/web/url&gt;
</code></pre>
<p>This is essentially the same as the following in the non-Kubernetes world:</p>
<pre><code>curl &lt;/some/web/url&gt; |bash
</code></pre>
<p>In both cases, we aren't inspecting the content downloaded from the URL and directly executing them by feeding to <code>kubectl</code> and <code>bash</code> directly. <strong>What if the URL is compromised with some harmful code?</strong></p>
<p>A better approach is to break the single step into parts:</p>
<ol>
<li>Download the manifest file</li>
<li>Inspect the manifest file.</li>
<li>Run kubectl apply/create on it, only you are satisfied.</li>
</ol>
<p><strong>Example</strong>:<br />
<em>//download the file</em></p>
<pre><code>curl -fsSL -o downloaded.yml https://deploy.kubemq.io/community
</code></pre>
<p><em>// inspect the file or edit the file</em></p>
<p><em>//Now apply the downloaded file after inspecting.</em></p>
<pre><code>kubectl apply -f downloaded.yml
</code></pre>
