PipeCD – PipeCD
https://pipecd.dev/
Recent content on PipeCDHugo -- gohugo.ioenBlog: What is new in pipedv1 (plugin-arch piped)
https://pipecd.dev/blog/2025/09/02/what-is-new-in-pipedv1-plugin-arch-piped/
Tue, 02 Sep 2025 00:00:00 +0000https://pipecd.dev/blog/2025/09/02/what-is-new-in-pipedv1-plugin-arch-piped/
<p>Since the alpha release from Jun 2025, plugin-arch piped (aka. pipedv1) is closer to first offical release, we are working on v1.0.0-rc0 and will be released in the coming days.</p>
<p>In this article I would like to share some improvements that have been fixed in the new version pipedv1 compared to its predecessor piped.</p>
<h2 id="overview">Overview</h2>
<p>While developing pipedv1, we always considered ensuring backward compatibility, meaning that the features available in piped will be mostly preserved in pipedv1. This ensures seamlessness between using piped and pipedv1, reducing the risk of problems when switching to pipedv1.</p>
<p>Changes in pipedv1 are of 2 types:</p>
<ul>
<li>
<p>Performance improvements or addressing some features requested in pipedv0 but could not be met due to technical reasons.</p>
</li>
<li>
<p>Removal of some features that are obsolete or no longer prioritized</p>
</li>
</ul>
<p>Fundamental changes like pipedv1 being able to support different platforms and making build pipeline deployment more powerful by turning stage executors into plugins have been described in <a href="https://pipecd.dev/blog/2024/11/28/overview-of-the-plan-for-pluginnable-pipecd/">this blog</a>. This post will focus on smaller changes related to the actual usage of pipecd.</p>
<h2 id="new-in-pipedv1">New in pipedv1</h2>
<h3 id="plugins-configurations"><code>plugins</code> configurations</h3>
<p>From pipedv1, plugin binaries will be the real executor that perform pipeline’s stages execution.
Plugin configuration is placed in 2 locations: <strong>piped config</strong> and <strong>application config</strong>.</p>
<p>The <strong>piped config</strong> is where basic plugin configurations are stored, such as where to load the plugin binary or some configurations that can be shared between applications.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Piped</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">projectID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">dev</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipedID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">xxx</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">plugins</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">kubernetes</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">7001</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/pipe-cd/pipecd/releases/download/link-to-plugin</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">deployTargets</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">local</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubectlVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">1.32.4</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">remote</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubectlVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">1.33.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">wait</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">7002</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/pipe-cd/pipecd/releases/download/link-to-plugin</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>NOTE: <code>platformProviders</code> and <code>cloudProviders</code> in piped config will not be available in pipedv1 config. Instead, the <code>deployTargets</code> configuration in plugin config will determine where to deploy your application resources.</p>
<p>Meanwhile, the <strong>application config</strong> is where plugin configurations are stored specifically for the deployment of that application.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">local</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">planner</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">alwaysUsePipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">true</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S-SYNC</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">plugins</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubernetes</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">input</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubectlVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">1.33.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">quickSync</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">prune</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">true</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Pipedv1 automatically identifies plugins based on the stage defined in the pipeline configuration. Which means below application config is valid as well</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">local</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S-SYNC</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>For applications config without a pipeline definition, <code>plugins</code> config is required to help piped infer the plugin needed while performing deployment</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-k8s-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">local</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">plugins</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubernetes</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>NOTE: <code>kind: XXXApp</code> is deprecated in pipedv1, <code>kind: Application</code> will be used for all applications in app configuration file for pipedv1 managed application.</p>
<p><strong>Migrating application configs to the new format will be covered in detail in another blog</strong>. You can learn more about the migration flow for now please check out <a href="https://github.com/pipe-cd/pipecd/issues/5542#issuecomment-3223865130">the migration issue</a>.</p>
<h3 id="pipeline-planning-and-configuration">Pipeline planning and configuration</h3>
<p>Creating pipelines based on different deployment strategies for various specific applications is a strong point that makes PipeCD stand out. With pipedv1, this feature is further enhanced by solving some old limitations in the current piped.</p>
<p>Since pipedv1, you can create a pipeline consisting of only one SYNC stage.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_SYNC</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Or optionally, create a pipeline that includes the SYNC stage combined with other common stages, for example.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30s</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_SYNC</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30s</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h3 id="stages-configurations">Stages configurations</h3>
<p>Regarding stages (units of the pipecd pipeline), a feature that has been requested by many users is <code>skipOn</code>, which allows skipping a stage in the application deployment pipeline under certain conditions.</p>
<p>In the current version of piped, skipOn is only supported in limited ways for some stages (like Analysis Stage - ref: <a href="https://pipecd.dev/docs-v0.53.x/user-guide/configuration-reference/#analysisstageoptions">docs</a>), in pipedv1, all stages support this feature.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">skipOn</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">paths</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#4e9a06">'*/canary'</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30s</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>An unstable feature in piped is stage timeout, in pipedv1 version, all stages also support timeout settings. The default stage timeout will be 6 hours.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">test-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT_APPROVAL</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">timeout</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">1h</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Default is 6h</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">approvers</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#000">khanhtc1202</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h2 id="deprecated--dis-supported-features">Deprecated / Dis-supported features</h2>
<h3 id="weird-flag---enable-default-kubernetes-cloud-provider-in-piped-execution">“Weird” flag <code>--enable-default-kubernetes-cloud-provider</code> in piped execution</h3>
<p>A long-time “weird” flag for piped binary execution if you don’t use PipeCD for a Kubernetes application is <code>--enable-default-kubernetes-cloud-provider</code>, which is basically legacy due to the first implementation of PipeCD focusing on supporting only Kubernetes. The default value is <code>false</code>, but if you set that flag to <code>true</code>, piped execution requires connecting to the Kubernetes cluster even before any application deployment is actually triggered.</p>
<p>In pipedv1, nothing like that flag exists in piped execution because pipedv1 supports whatever platform its plugins support equally.</p>
<h3 id="kubernetes-templating-feature">Kubernetes templating feature</h3>
<p>Related to Kubernetes support features of PipeCD. Currently, piped supports the Helm Git Remote Chart feature (ref <a href="https://pipecd.dev/docs-v0.53.x/user-guide/managing-piped/configuration-reference/#chartrepository">piped config helm chart repository</a>), which pulls the chart file stored directly on Git to the local and builds/templates as for a Local Chart.</p>
<p>With the emergence and standardization of OCI, storing and sharing Helm Charts has become easier via the <a href="https://helm.sh/docs/helm/helm_registry/">Helm registry</a>. Therefore, in pipedv1, we decided to stop supporting this feature.</p>
<h3 id="analysis-stage-query-templating-feature">Analysis stage query templating feature</h3>
<p>Current piped support building queries used while evaluating metrics with deployment-specific data to be embedded in the analysis template (ref: <a href="https://pipecd.dev/docs-v0.53.x/user-guide/managing-application/customizing-deployment/automated-deployment-analysis/#optional-analysis-template">analysis templating docs</a>).</p>
<p>From pipedv1, along with built-in and custom args are supported with placeholders as <code>{{ .App }}</code> and <code>{{ .AppCustomArgs }}</code> respectively.</p>
<p>Kubernetes-specific built-in args like <code>{{ .K8s.Namespace }}</code> will be marked as deprecated and unsupported after several releases. The corresponding usage for the Kubernetes Namespace use case is changed to <code>{{ .AppCustomArgs.k8sNamespace }}</code>.</p>
<h2 id="summary">Summary</h2>
<p>Here are some changes you might notice when switching to pipedv1. We ensure a certain level of backward compatibility between piped and pipedv1. The improvements are all aimed at making pipedv1 support more platforms and making it easier to build pipelines based on plugins.</p>
<p>The official documentation for pipedv1 is still being prepared, and the experimental release of pipedv1 will be available on the <a href="https://github.com/pipe-cd/pipecd/releases">official pipecd repo release tab</a>, along with some built-in plugins in the next few days.</p>
<p>Thanks for your attention, cheer 🍻</p>
Blog: Plugin architecture Piped alpha version has been released
https://pipecd.dev/blog/2025/06/16/plugin-architecture-piped-alpha-version-has-been-released/
Mon, 16 Jun 2025 00:00:00 +0000https://pipecd.dev/blog/2025/06/16/plugin-architecture-piped-alpha-version-has-been-released/
<p>It has been months from the <a href="https://pipecd.dev/blog/2024/11/28/overview-of-the-plan-for-pluginnable-pipecd/">Piped plugin architecture</a> blog, and after over a year of development, we happy to announce that the alpha version of Piped is ready 🎉</p>
<p>In this blog, we will show you how to run the plugin-arch piped with some built in plugins developed by the maintainers team.</p>
<p><em>If you want to know more about the plugin-arch piped internal, please read the <a href="https://github.com/pipe-cd/pipecd/blob/master/cmd/pipedv1/README.md">pipedv1 README</a> in pipecd repo.</em></p>
<h2 id="prerequisites">Prerequisites</h2>
<ul>
<li>kubectl and a k8s cluster (They are not required if you won’t use the kubernetes plugin)</li>
</ul>
<h2 id="1-setup-control-plane">1. Setup Control Plane</h2>
<ol>
<li>
<p>Run a Control Plane that your piped will connect to. If you want to run a Control Plane locally, see <a href="https://github.com/pipe-cd/pipecd/blob/master/cmd/pipecd/README.md#how-to-run-control-plane-locally">How to run Control Plane locally</a>.</p>
<ul>
<li>The Control Plane version must be v0.52.0 or later.</li>
</ul>
</li>
<li>
<p>Generate a new piped key/ID.</p>
<p>2.1. Access the Control Plane console.</p>
<p>2.2. Go to the piped list page. (https://{console-address}/settings/piped)</p>
<p>2.4. Add a new piped via the <code>+ADD</code> button.</p>
<p>2.5. Copy the generated piped ID and base64 encoded key.</p>
</li>
</ol>
<h2 id="2-run-plugin-arched-piped">2. Run plugin-arched piped</h2>
<ol>
<li>Download piped binary.</li>
</ol>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># OS="darwin" or "linux" CPU_ARCH="arm64" or "amd64"</span>
</span></span><span style="display:flex;"><span>curl -Lo ./piped_kubecon_jp_2025 https://github.com/pipe-cd/pipecd/releases/download/kubecon-jp-2025/piped_kubecon_jp_2025_<span style="color:#ce5c00;font-weight:bold">{</span>OS<span style="color:#ce5c00;font-weight:bold">}</span>_<span style="color:#ce5c00;font-weight:bold">{</span>CPU_ARCH<span style="color:#ce5c00;font-weight:bold">}</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>chmod +x ./piped_kubecon_jp_2025
</span></span></code></pre></div><ol start="2">
<li>Create a piped config file like the following.</li>
</ol>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Piped</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">apiAddress</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span>{<span style="color:#000">CONTROL_PLANE_API_ADDRESS}</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># like "localhost:8080"</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">projectID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span>{<span style="color:#000">PROJECT_ID}</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipedID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span>{<span style="color:#000">PIPED_ID}</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipedKeyData</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span>{<span style="color:#000">BASE64_ENCODED_PIPED_KEY}</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># or use pipedKeyFile</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">repositories</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">repoID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">repo1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">remote</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/your-account/your-repo</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">branch</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">xxx</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># See https://pipecd.dev/docs/user-guide/managing-piped/configuration-reference/ for details of above.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># platformProviders is not necessary.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">plugins</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">kubernetes</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">7001</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Any unused port</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/pipe-cd/pipecd/releases/download/kubecon-jp-2025/plugin_kubernetes_kubecon_jp_2025_darwin_arm64</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># choose binary on the release for your own OS and CPU arch</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">deployTargets</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">cluster1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">masterURL</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://127.0.0.1:61337 </span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># shown by kubectl cluster-info</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubeConfigPath</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">/path/to/kubeconfig</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubectlVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">1.33.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">wait</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">7002</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Any unused port</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/pipe-cd/pipecd/releases/download/kubecon-jp-2025/plugin_wait_kubecon_jp_2025_darwin_arm64</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># choose binary on the release for your own OS and CPU arch</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example-stage</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">7003</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Any unused port</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/pipe-cd/community-plugins/releases/download/kubecon-jp-2025/plugin_example-stage_kubecon_jp_2025_darwin_arm64</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># choose binary on the release for your own OS and CPU arch</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">commonMessage</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#4e9a06">"[common message]"</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><ol start="3">
<li>Run piped</li>
</ol>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span>./piped_kubecon_jp_2025 piped --config-file<span style="color:#ce5c00;font-weight:bold">=</span>/path/to/piped-config.yaml --tools-dir<span style="color:#ce5c00;font-weight:bold">=</span>/tmp/piped-bin
</span></span></code></pre></div><ul>
<li>If your Control Plane runs on local, add <code>--insecure=true</code> to the command to skip TLS certificate checks.</li>
</ul>
<h2 id="3-deploy-an-application">3. Deploy an application</h2>
<p>Let’s create application with kubernetes plugin.</p>
<ol>
<li>
<p>Create an app.pipecd.yaml like the following.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Application</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">team</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">product</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Deploy the workloads of CANARY variant. In this case, the number of</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># workload replicas of CANARY variant is 10% of the replicas number of PRIMARY variant.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_CANARY_ROLLOUT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">replicas</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">10</span><span style="color:#000">%</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Wait 10 seconds before going to the next stage.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">10s</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Update the workload of PRIMARY variant to the new version.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_PRIMARY_ROLLOUT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Destroy all workloads of CANARY variant.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_CANARY_CLEAN</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div></li>
<li>
<p>Create Resources in the same dir as app.pipecd.yaml.</p>
<p>deployment.yaml</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">apps/v1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Deployment</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">metadata</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">app</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">replicas</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">2</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">revisionHistoryLimit</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">2</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">selector</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">matchLabels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">app</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipecd.dev/variant</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">primary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">template</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">metadata</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">app</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipecd.dev/variant</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">primary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">containers</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">helloworld</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">image</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ghcr.io/pipe-cd/helloworld:v0.32.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">args</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#000">server</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">ports</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">containerPort</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">9085</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>service.yaml</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">v1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Service</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">metadata</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">selector</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">app</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">canary</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">ports</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">protocol</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">TCP</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">port</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">9085</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">targetPort</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">9085</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div></li>
<li>
<p>Push the app.pipecd.yaml and the resources to your remote repository.</p>
</li>
<li>
<p>On the Control Plane console, register the application via <code>PIPED V1 ADD FROM SUGGESTIONS</code> tab.</p>
</li>
</ol>
<h2 id="see-also">See also</h2>
<p>Want to read more about the built in plugins of the new piped. Checkout the following docs</p>
<ul>
<li>kubernetes plugin: <a href="https://github.com/pipe-cd/pipecd/blob/master/pkg/app/pipedv1/plugin/kubernetes/README.md">README.md</a></li>
<li>wait stage plugin: <a href="https://github.com/pipe-cd/pipecd/blob/master/pkg/app/pipedv1/plugin/wait/README.md">README.md</a></li>
</ul>
<h2 id="and-more">And more</h2>
<p>Another hot news, we want to share you this time. As part of PipeCD team activity at <a href="https://events.linuxfoundation.org/kubecon-cloudnativecon-japan/program/schedule/">KubeCon Japan 2025</a>, the <a href="https://github.com/pipe-cd/community-plugins">piped community plugins repository</a> is officially opened 🎉</p>
<p>If you’re interested, join us, discuss pipecd at KubeCon Japan and fire some PRs to community-plugins repo. We are happy to help you build your desired deployment pipeline and plugins.</p>
<p>Let’s build and connect!</p>
Blog: MCP Server for PipeCD Docs Has Been Released
https://pipecd.dev/blog/2025/05/26/mcp-server-for-pipecd-docs-has-been-released/
Mon, 26 May 2025 00:00:00 +0000https://pipecd.dev/blog/2025/05/26/mcp-server-for-pipecd-docs-has-been-released/
<h2 id="introduction">Introduction</h2>
<p>Finding the right information in the official PipeCD docs can sometimes be challenging due to its volume.
To address this, we have developed the “<strong>PipeCD Docs Local MCP Server</strong>,” which allows you to perform full-text searches on the official documentation locally.<br>
This server automatically fetches the PipeCD docs from GitHub and provides simple APIs for full-text search via the <a href="https://modelcontextprotocol.io/introduction">MCP protocol</a>.</p>
<p>The repository is here: <a href="https://github.com/pipe-cd/docs-mcp-server">https://github.com/pipe-cd/docs-mcp-server</a></p>
<h2 id="example">Example</h2>
<p>For example, when I ask Cursor how to configure PipeCD for ECS, Cursor will search docs via the MCP server like this:</p>
<p><img src="https://pipecd.dev/images/mcp-server-intro-example1.png" alt=""></p>
<h2 id="usage">Usage</h2>
<p>See <a href="https://github.com/pipe-cd/docs-mcp-server/blob/main/README.md">README</a> for details.</p>
<p>After preparing npm config to fetch the package from GitHub Packages registry, you can simply run the server by <code>npx @pipe-cd/docs-mcp-server@latest</code>.</p>
<p>For example, for Cursor editor, add the following to your <code>mcp.json</code>:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-json" data-lang="json"><span style="display:flex;"><span><span style="color:#000;font-weight:bold">{</span>
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">"mcpServers"</span><span style="color:#000;font-weight:bold">:</span> <span style="color:#000;font-weight:bold">{</span>
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">"pipe-cd.docs-mcp-server"</span><span style="color:#000;font-weight:bold">:</span> <span style="color:#000;font-weight:bold">{</span>
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">"type"</span><span style="color:#000;font-weight:bold">:</span> <span style="color:#4e9a06">"stdio"</span><span style="color:#000;font-weight:bold">,</span>
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">"command"</span><span style="color:#000;font-weight:bold">:</span> <span style="color:#4e9a06">"npx"</span><span style="color:#000;font-weight:bold">,</span>
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">"args"</span><span style="color:#000;font-weight:bold">:</span> <span style="color:#000;font-weight:bold">[</span>
</span></span><span style="display:flex;"><span> <span style="color:#4e9a06">"@pipe-cd/docs-mcp-server@latest"</span>
</span></span><span style="display:flex;"><span> <span style="color:#000;font-weight:bold">]</span>
</span></span><span style="display:flex;"><span> <span style="color:#000;font-weight:bold">}</span>
</span></span><span style="display:flex;"><span> <span style="color:#000;font-weight:bold">}</span>
</span></span><span style="display:flex;"><span><span style="color:#000;font-weight:bold">}</span>
</span></span></code></pre></div><h2 id="mcp-tools">MCP Tools</h2>
<p>The MCP Server provides two tools for now:</p>
<ul>
<li><code>search_docs</code>: Performs full-text search with keywords.</li>
<li><code>read_docs</code>: Retrieves the content of a specified page.</li>
</ul>
<h2 id="development-highlights">Development Highlights</h2>
<ul>
<li>
<p><strong>Efficient cloning with sparse checkout</strong><br>
Only the necessary directory (<code>docs/content/en</code>) is cloned to speed up processing.</p>
</li>
<li>
<p><strong>Simple Search Logic</strong><br>
The current search logic is simple: it prioritizes title matches, followed by content matches.</p>
</li>
</ul>
<h2 id="conclusion">Conclusion</h2>
<p>We hope this tool helps PipeCD users to configure or find information more efficiently.
Contributions, including bug reports and feature requests are welcome via <a href="https://github.com/pipe-cd/docs-mcp-server/issues">Issues</a>.</p>
Blog: What Happens before Deployment? GitOps Mechanism
https://pipecd.dev/blog/2025/04/28/what-happens-before-deployment-gitops-mechanism/
Mon, 28 Apr 2025 00:00:00 +0000https://pipecd.dev/blog/2025/04/28/what-happens-before-deployment-gitops-mechanism/
<p>This article explains the process before a deployment begins in PipeCD. Since PipeCD is pull-based, there are various processes that take place before a deployment starts.</p>
<p>Probably, you have felt “What is Pending??” at least once:
<img src="https://pipecd.dev/images/before-deploy-pending.png" alt="Pending"></p>
<p>The target audience is those who want to:</p>
<ul>
<li>troubleshoot when “deployment doesn’t start as expected…”</li>
<li>understand GitOps mechanisms and implementation</li>
<li>contribute to PipeCD</li>
</ul>
<p><em>This article is based on PipeCD v0.51.2 (latest version at time of writing). The specifications in the <a href="https://zenn.dev/cadp/articles/pipecd-plugin-intro">plugin version</a> are slightly different.</em></p>
<p><em>This article omits discussion of <a href="https://pipecd.dev/docs-v0.51.x/user-guide/managing-application/deployment-chain/">Deployment Chain</a> (due to complexity).</em></p>
<h2 id="overview">Overview</h2>
<p>The state transitions before deployment begins are shown in the diagram below.</p>
<pre class="mermaid">stateDiagram-v2
Not_Started --> PENDING: [1] Trigger
PENDING --> PLANNED: [2] Plan (Determine pipeline)
PLANNED --> RUNNING: [3] Schedule (Execute stages)
</pre>
<p>Phases [1] through [3] are <strong>executed asynchronously by separate components (goroutines)</strong>. This mechanism allows deployment to resume even if Piped crashes during the process.</p>
<p><img src="https://pipecd.dev/images/before-deploy-components.drawio.png" alt=""></p>
<h2 id="1-trigger">1. Trigger</h2>
<p>PipeCD initiates application deployment through four types of triggers:</p>
<ul>
<li>[A] Detecting changes in Git (main method)
<ul>
<li>Includes integration from CI through <a href="https://pipecd.dev/docs/user-guide/managing-piped/configuring-event-watcher/">EventWatcher</a></li>
</ul>
</li>
<li>[B] Manual start from UI/pipectl</li>
<li>[C] Automatic deployment on drift detection (requires configuration)</li>
<li>[D] Deployment Chain (details omitted)</li>
</ul>
<p>The above four points can be configured <a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#deploymenttrigger"><code>trigger</code></a> in <code>app.pipecd.yaml</code>. <strong>Only [C] is disabled by default</strong>.</p>
<h4 id="a-detecting-changes-in-git">[A] Detecting changes in Git</h4>
<p>This occurs when the following two conditions are met after fetching the latest commit from the Git repository:</p>
<ol>
<li>There are new commits that haven’t been deployed</li>
<li>There is at least one change in files at the same level or below <code>app.pipecd.yaml</code></li>
</ol>
<p>For 2., the detection scope can be adjusted using <a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#oncommit"><code>paths</code>/<code>ignores</code> settings</a>. This allows detection of changes in shared template files located in different directories, for example.</p>
<h4 id="b-manual-trigger-from-uipipectl">[B] Manual trigger from UI/pipectl</h4>
<p>This is a push-style pattern.</p>
<p>From the UI, you can start it on the Application page. This is convenient for cases like “redeploying after a deployment failure due to environment issues rather than application issues.”</p>
<p>You can also start it from pipectl using the <a href="https://pipecd.dev/docs-v0.51.x/user-guide/command-line-tool/#syncing-an-application">following command</a>. This is useful for cases like “direct deployment from CI (exceptionally) or workflows.”</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span>pipectl application sync --app-id<span style="color:#ce5c00;font-weight:bold">={</span>app-id<span style="color:#ce5c00;font-weight:bold">}</span>
</span></span></code></pre></div><h4 id="c-automatic-deployment-on-drift-detection-requires-configuration">[C] Automatic deployment on drift detection (requires configuration)</h4>
<p>This occurs when there’s a difference between the Git definition (=desired state) and the actual environment. PipeCD has a separate mechanism called <a href="https://pipecd.dev/docs-v0.51.x/user-guide/managing-application/configuration-drift-detection/">Drift Detection</a> that continuously detects drifts.</p>
<p>This trigger is disabled by default, and manual repair is the basic approach after drift detection. This trigger is for those who want to strictly treat Git as the Single Source of Truth.</p>
<p>Deployment is triggered when an application meets all four of the following conditions:</p>
<ol>
<li>“Automatic deployment on drift detection” is enabled
<ul>
<li>Set the <code>trigger.onOutOfSync.disabled</code> item to <code>false</code> (<strong>default is <code>true</code></strong>)</li>
</ul>
</li>
<li>Drift has occurred (status is <code>OutOfSync</code>)</li>
<li>Not currently deploying</li>
<li>A specified time has passed since the last deployment (default is 5 minutes)
<ul>
<li>This prevents the scenario where “deployment completes but the drift detection mechanism is delayed, causing false drift detection and deployment”</li>
<li>Can be configured with the <code>trigger.onOutOfSync.minWindow</code> item</li>
</ul>
</li>
</ol>
<p><a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#onoutofsync">https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#onoutofsync</a></p>
<h4 id="trigger-code">Trigger code</h4>
<p>See the <code>trigger</code> package, <code>trigger.go</code> is the entry point and <code>determiner.go</code> determines whether to deploy or not.</p>
<p>Personally, reading the <code>trigger</code> package significantly improves understanding of PipeCD’s behavior.</p>
<p><a href="https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/trigger/">https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/trigger/</a></p>
<h2 id="2-plan-determine-pipeline">2. Plan: Determine Pipeline</h2>
<p>This phase determines “how to deploy using which pipeline.” It mainly does two things:</p>
<ol>
<li>Determine whether to use Quick Sync or Pipeline Sync</li>
<li>Determine stages</li>
</ol>
<p>The planner instance runs as a goroutine in a 1:1 relationship with Deployment, allowing multiple deployments to be processed concurrently.
Also, piped is implemented to prevent multiple deployments from running simultaneously for the same application.</p>
<h4 id="21-determining-quick-sync-or-pipeline-sync">2.1. Determining Quick Sync or Pipeline Sync</h4>
<h5 id="what-are-quick-sync-and-pipeline-sync">What are Quick Sync and Pipeline Sync?</h5>
<p>PipeCD has two deployment strategies:</p>
<ul>
<li>
<p><strong>Quick Sync</strong></p>
<ul>
<li>Executes deployment with a single stage (<code>K8S_SYNC</code> or <code>ECS_SYNC</code>, etc.)</li>
<li>Optimal for cases where “only Git synchronization is needed, no analysis required”</li>
</ul>
</li>
<li>
<p><strong>Pipeline Sync</strong></p>
<ul>
<li>Executes deployment according to a defined pipeline</li>
<li>Optimal for cases requiring staged deployment like Canary deployment</li>
</ul>
</li>
</ul>
<h5 id="strategy-determination-logic">Strategy determination logic</h5>
<p><strong>Quick Sync is selected when any of the following conditions are met:</strong></p>
<ul>
<li>[A] User manually starts deployment from UI selecting “Quick Sync”</li>
<li>[B] No <code>pipeline</code> is configured in <code>app.pipecd.yaml</code></li>
<li>[C] (k8s only) Conditions in <code>app.pipecd.yaml</code>’s <a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#commitmatcher"><code>planner.commitMatcher.quickSync</code></a> are met</li>
<li>[D] (except Terraform) No successful deployment exists for that application</li>
<li>[E] (k8s only) No changes in workload or config (<a href="https://pipecd.dev/docs-v0.51.x/user-guide/managing-application/defining-app-configuration/kubernetes/#quick-sync">details</a>)</li>
</ul>
<p><strong>Pipeline Sync is selected when any of the following conditions are met:</strong></p>
<ul>
<li>[A] User manually starts deployment from UI selecting “Pipeline Sync”</li>
<li>[B] <code>planner.alwaysUsePipeline</code> is set to <code>true</code> in <code>app.pipecd.yaml</code> (default is <code>false</code>)</li>
<li>[C] (k8s only) Conditions in <code>app.pipecd.yaml</code>’s <a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#commitmatcher"><code>planner.commitMatcher.pipeline</code></a> are met</li>
</ul>
<p>The detailed decision flowchart is like this:</p>
<pre class="mermaid">flowchart TD
Start[Start] --> UI{Triggered from UI and selected 'Auto'?}
UI -->|Quick Sync selected| QuickSync
UI -->|Not from UI or selected 'Auto'| Pipeline{Pipeline configured in app.pipecd.yaml?}
UI -->|Pipeline Sync selected| PipelineSync
Pipeline-->|No| QuickSync
Pipeline-->|Yes| CommitMatcherPipe{**k8s only**: meets commitMatcher.pipeline conditions in app.pipecd.yaml?}
CommitMatcherPipe-->|No / non-k8s | CommitMatcherQuick{**k8s only**: meets commitMatcher.quickSync conditions in app.pipecd.yaml?}
CommitMatcherPipe-->|Yes| PipelineSync
CommitMatcherQuick-->|Yes| QuickSync
CommitMatcherQuick-->|No / non-k8s | Always{alwaysUsePipeline=true in app.pipecd.yaml?}
Always-->|No| Succeeded{Successful deployment exists?}
Always-->|Yes| PipelineSync
Succeeded-->|No| QuickSync
Succeeded-->|Yes| Varied{Platform-specific determination logic}
Varied --> QuickSync
Varied --> PipelineSync
</pre>
<h4 id="22-determining-stages">2.2. Determining Stages</h4>
<p>There’s not much noteworthy here.</p>
<ul>
<li>
<p>For Quick Sync:</p>
<ul>
<li>Since there’s no user-defined pipeline, generates stages like <code>K8S_SYNC</code> for K8s or <code>ECS_SYNC</code> for ECS</li>
</ul>
</li>
<li>
<p>For Pipeline Sync:</p>
<ul>
<li>Generates stages according to the user-defined pipeline</li>
</ul>
</li>
</ul>
<h4 id="planner-code">Planner code</h4>
<p>The core logic of Plan is implemented per platform in the <code>planner</code> package. The <code>controller</code> package controls its execution.</p>
<p><a href="https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/planner/kubernetes/kubernetes.go">https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/planner/kubernetes/kubernetes.go</a></p>
<h2 id="3-schedule-execute-pipeline">3. Schedule: Execute Pipeline</h2>
<p>The scheduler component manages pipeline progression. It mainly does two things:</p>
<ol>
<li>Execute each stage of the pipeline</li>
<li>Execute rollback on failure</li>
</ol>
<p>Like the planner, the scheduler instance runs as a goroutine in a 1:1 relationship with Deployment, allowing multiple deployments to be processed concurrently.</p>
<h4 id="31-executing-each-stage-of-the-pipeline">3.1. Executing Each Stage of the Pipeline</h4>
<p>Executes each stage sequentially based on the pipeline generated in the Plan phase.
Specific processing content varies by platform.</p>
<h4 id="32-executing-rollback-on-failure">3.2. Executing Rollback on Failure</h4>
<p>If any stage fails, executes the rollback stage.
Like 3.1., the rollback stage name and processing content vary by platform.</p>
<h4 id="scheduler-code">Scheduler code</h4>
<p>The <code>Run()</code> and <code>executeStage()</code> methods in <code>scheduler.go</code> of the <code>controller</code> package are important.</p>
<p><a href="https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/controller/scheduler.go#L191-L661">https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/controller/scheduler.go#L191-L661</a></p>
<p>The specific processing logic of each stage is in the <a href="https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/executor/"><code>executor</code> package</a>.
The <code>executor</code> package describes “execute this process in this stage,” making it relatively easy to understand.</p>
<h2 id="appendix-what-is-the-controller">Appendix: What is the controller?</h2>
<p>This section is intended for those interested in code reading.</p>
<p>The controller is the manager of the planner and scheduler. Users don’t need to be aware of it.</p>
<p>The controller package, which contains the planner and scheduler, includes code related to deployment flow control. The <a href="https://github.com/pipe-cd/pipecd/blob/v0.51.2/pkg/app/piped/controller/controller.go"><code>controller.go</code></a> is the entry point, and the controller runs continuously from Piped startup.</p>
<p>The controller performs the following every 10 seconds:</p>
<ul>
<li>Create planner/scheduler for new deployments if needed</li>
<li>Delete completed planner/scheduler</li>
<li>Notify planner/scheduler when a user cancels deployment</li>
</ul>
<h2 id="conclusion">Conclusion</h2>
<p>While PipeCD has many other features and code, the trigger and controller form its core.
I hope this helps find which code to get hints when you think “it would be nice if PipeCD had a feature like xxx.”</p>
Blog: Introduction to EventWatcher: Connecting CI to PipeCD
https://pipecd.dev/blog/2025/04/28/introduction-to-eventwatcher-connecting-ci-to-pipecd/
Mon, 28 Apr 2025 00:00:00 +0000https://pipecd.dev/blog/2025/04/28/introduction-to-eventwatcher-connecting-ci-to-pipecd/
<p>This article explains the basics of “<strong>EventWatcher</strong>”, a crucial feature in practical PipeCD usage.</p>
<p>This article is intended for those who:</p>
<ul>
<li>“Don’t know how to integrate CI with PipeCD”</li>
<li>“Have found the EventWatcher feature but can’t grasp how it works”</li>
</ul>
<p><em>This article is based on PipeCD v0.51.2 (latest at the time of writing).</em></p>
<h2 id="background-why-eventwatcher-is-needed">Background: Why EventWatcher is needed</h2>
<p>Basically, PipeCD is a CD tool that continuously deploys specified config/manifests.</p>
<p><img src="https://pipecd.dev/images/eventwatcher-only-cd.drawio.png" alt=""></p>
<p>Deployment typically requires manifest changes. So, how can we “<strong>deploy using a new image (etc.) after CI completion</strong>”? It’s annoying to update the manifest repo manually each time.</p>
<p><img src="https://pipecd.dev/images/eventwatcher-problem.drawio.png" alt=""></p>
<p>This is where the EventWatcher feature comes into play!</p>
<h2 id="what-is-eventwatcher">What is EventWatcher?</h2>
<p>EventWatcher is a feature in PipeCD that seamlessly connects CI and CD. It updates the manifest repo based on events from CI, triggering CD.</p>
<p><a href="https://pipecd.dev/docs-v0.51.x/user-guide/event-watcher/">https://pipecd.dev/docs-v0.51.x/user-guide/event-watcher/</a></p>
<h3 id="mechanism">Mechanism</h3>
<p>The overall picture of EventWatcher looks like the diagram below.</p>
<p><img src="https://pipecd.dev/images/eventwatcher-overview.drawio.png" alt=""></p>
<p>The EventWatcher feature itself handles steps 4-6:</p>
<ul>
<li>
<p>1-3. Develop new app code and store the results (container images, etc.) in a container registry</p>
</li>
<li>
<p><strong>4.</strong> Publish an event in CI to pass the new image URI to PipeCD</p>
</li>
<li>
<p><strong>5.</strong> Piped detects the event</p>
</li>
<li>
<p><strong>6.</strong> Update the manifest repo using the data provided by the event (image URI, etc.)</p>
</li>
<li>
<p>7-8. Automatic deployment occurs through the standard deployment flow of PipeCD</p>
</li>
</ul>
<h2 id="usage">Usage</h2>
<p>You need to setup three areas:</p>
<h4 id="1-piped-configuration">1. Piped Configuration</h4>
<ol>
<li>Which manifest repo events to handle</li>
<li>Commit permissions for the manifest repo</li>
</ol>
<p><a href="https://pipecd.dev/docs-v0.51.x/user-guide/managing-piped/configuring-event-watcher/">https://pipecd.dev/docs-v0.51.x/user-guide/managing-piped/configuring-event-watcher/</a></p>
<h4 id="2-apppipecdyaml-configuration">2. app.pipecd.yaml Configuration</h4>
<ol>
<li>Which events to handle for the Application (<code>matcher</code>)</li>
<li>What actions to take for matched events (<code>handler</code>)</li>
</ol>
<p>(Example) Configuration to update the <code>spec.template.spec.containers[0].image</code> field in <code>deployment.yaml</code> when the <code>helloworld-image-update</code> event is triggered:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">helloworld</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">eventWatcher</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">matcher</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Which events to handle</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">helloworld-image-update</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">handler</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># What actions to take</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">GIT_UPDATE</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">replacements</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">file</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">deployment.yaml</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">yamlField</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">$.spec.template.spec.containers[0].image</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Full configuration reference:
<a href="https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#eventwatcher">https://pipecd.dev/docs-v0.51.x/user-guide/configuration-reference/#eventwatcher</a></p>
<h4 id="3-event-triggering-via-pipectl-or-github-actions">3. Event Triggering via pipectl or GitHub Actions</h4>
<ol>
<li>Event name (set in <code>app.pipecd.yaml</code> as <code>matcher.name</code>)</li>
<li>New value (image URI, etc.)</li>
</ol>
<p>(Example) Command to trigger an event named <code>helloworld-image-update</code> to change the image URI to <code>ghcr.io/xxx/helloworld:v0.2.0</code>:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span>pipectl event register <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span> --address<span style="color:#ce5c00;font-weight:bold">={</span>CONTROL_PLANE_API_ADDRESS<span style="color:#ce5c00;font-weight:bold">}</span> <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span> --api-key<span style="color:#ce5c00;font-weight:bold">={</span>API_KEY<span style="color:#ce5c00;font-weight:bold">}</span> <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span> --name<span style="color:#ce5c00;font-weight:bold">=</span>helloworld-image-update <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span> --data<span style="color:#ce5c00;font-weight:bold">=</span>ghcr.io/xxx/helloworld:v0.2.0
</span></span></code></pre></div><p>If you use GitHub Actions for your CI, using PipeCD’s official <code>actions-event-register</code> is recommended (configurations are the same):</p>
<p><a href="https://github.com/marketplace/actions/pipecd-register-event">https://github.com/marketplace/actions/pipecd-register-event</a></p>
<p>For example, triggering an event named <code>helloworld-image-update</code> to change the image URI to <code>ghcr.io/xxx/helloworld:v0.2.0</code>:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">uses</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipe-cd/[email protected]</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">api-address</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">${{ secrets.API_ADDRESS }}</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">api-key</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">${{ secrets.API_KEY }}</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">event-name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">helloworld-image-update</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">data</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ghcr.io/xxx/helloworld:v0.2.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>You can also handle events differently by environment using the <code>--labels</code> option, even for events with the same name.</p>
<h5 id="advanced---contexts-option">Advanced: <code>--contexts</code> Option</h5>
<p>Adding <code>--contexts</code> to <code>pipectl event register</code> allows you to include various information in the manifest repo commit. For example, passing the <strong>“commit hash and URL of the app repo that triggered the event”</strong> makes it easier to track “which app repo changes caused this event” in the manifest repo. This is particularly useful when deployments occur frequently.</p>
<p><a href="https://pipecd.dev/docs-v0.51.x/user-guide/event-watcher/#optional-using-contexts">https://pipecd.dev/docs-v0.51.x/user-guide/event-watcher/#optional-using-contexts</a></p>
<h2 id="appendix-code-reading">Appendix: Code Reading</h2>
<p>The EventWatcher code is consolidated in one file (though it’s quite long). Remembering that “EventWatcher runs continuously as a goroutine from Piped startup” makes it slightly easier to read.</p>
<p><a href="https://github.com/pipe-cd/pipecd/blob/v0.50.2/pkg/app/piped/eventwatcher/eventwatcher.go">https://github.com/pipe-cd/pipecd/blob/v0.50.2/pkg/app/piped/eventwatcher/eventwatcher.go</a></p>
<h2 id="conclusion">Conclusion</h2>
<p>Using EventWatcher enables seamless integration between CI and CD. There are various advanced applications, and it would be great to see more examples being shared.</p>
<p>Additionally, <strong>Deployment Traces</strong> feature enhances the integration of CI and PipeCD. For more details, please see this article:</p>
<p><a href="https://pipecd.dev/blog/2024/12/26/the-gap-between-ci/cd-and-how-pipecd-appeared-to-fulfill-the-gap/">https://pipecd.dev/blog/2024/12/26/the-gap-between-ci/cd-and-how-pipecd-appeared-to-fulfill-the-gap/</a></p>
Blog: The Gap Between CI/CD and How PipeCD Appeared to FulFill the Gap
https://pipecd.dev/blog/2024/12/26/the-gap-between-ci/cd-and-how-pipecd-appeared-to-fulfill-the-gap/
Thu, 26 Dec 2024 00:00:00 +0000https://pipecd.dev/blog/2024/12/26/the-gap-between-ci/cd-and-how-pipecd-appeared-to-fulfill-the-gap/
<p>PipeCD became a CNCF Sandbox last year and has only just begun to attract the attention of the community, but it has a long history of development since its inception, more than four years ago.</p>
<p>In this article, I would like to share the fundamental CICD challenges that the PipeCD development and operations team at CyberAgent identified, how we solved them in the current version of PipeCD, and our future direction.</p>
<p><strong>Note:</strong> The content may be change in the future since it’s still under development.</p>
<h2 id="gitops-and-cicd">GitOps and CICD</h2>
<p>Although there are many different definitions and understandings, there are some commonalities when it comes to related concepts such as GitOps and CICD:</p>
<ul>
<li>CI/CD separation is necessary</li>
<li>CI belongs to the application source code scope, and the output of CI is the input of CD. CD belongs to the manifest source code scope, and the input of CD is the output of CI</li>
<li>CD tools perform tasks based on GitOps principles</li>
</ul>
<h2 id="eventwatcher-as-the-bridge-between-ci-and-cd">EventWatcher as the bridge between CI and CD</h2>
<p>Since the first version, which didn’t have much user feedback, the development team has been pushing testing and using dogfooding techniques as a way to detect shortcomings in PipeCD’s functionality.
Since these early days, the problem of effectively linking CI and CD has emerged.</p>
<p><img src="https://pipecd.dev/images/cicd-flow.png" alt=""></p>
<p>source: <a href="https://www.weave.works/blog/what-is-gitops-really">https://www.weave.works/blog/what-is-gitops-really</a></p>
<p>A common way to bypass the “immutability firewall” between CI and CD without paying too much attention to what CI is being used for is to rely on an artifact (container image) that is the common element between CI and CD. This approach is used by many popular CDs today, such as ArgoCD and FluxCD.</p>
<p><img src="https://pipecd.dev/images/image-watcher-flow.png" alt=""></p>
<p>In addition to advantages such as a generic interface (as it only depends on the container image itself), this approach also has limitations, such as:</p>
<ul>
<li>It needs to support many different container registries (Docker Hub, ECR, GCR, ACR, Harbor, etc.)</li>
<li>It can only support container images as the artifacts, and not other artifacts such as Helm Charts, Terraform modules, Lambda source zips, etc.</li>
<li>As the number of container images to be monitored increases, performance-related issues arise</li>
</ul>
<p>Because PipeCD’s most important feature is to support various platforms, being able to only support container images as artifacts is not suitable for PipeCD. Therefore, we decided to develop a new solution to solve this problem: EventWatcher.</p>
<p><img src="https://pipecd.dev/images/pipecd-event-watcher-flow.png" alt=""></p>
<p>Instead of choosing a container image as the interface between CI and CD, PipeCD directly uses events sent from CI to PipeCD as triggers for the CD pipeline.</p>
<p>An event is considered a command to PipeCD (similar to triggering a deployment from the UI). It contains information such as:</p>
<ul>
<li>The event definition name and event label, are used to determine which application deployments should be triggered when piped processes this event</li>
<li>Information about what data is used by piped when processing the event</li>
<li>Information specifying paths to fields in the manifest file</li>
</ul>
<p>For example, suppose you want to use PipeCD EventWatcher feature to auto trigger deployment for your Kubernetes application. You first need to update your application configuration manifest like this</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">helloworld</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">eventWatcher</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">matcher</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">event-test</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">handler</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">GIT_UPDATE</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">replacements</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">file</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">deployment.yaml</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">yamlField</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">$.spec.template.spec.containers[0].image</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Then, in the last step of your CI pipeline, you need to use pipectl to send an event to PipeCD controlplane like this</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>$ pipectl event register --name<span style="color:#ce5c00;font-weight:bold">=</span>event-test --data<span style="color:#ce5c00;font-weight:bold">=</span>ghcr.io/pipecd/helloworld:v0.49.0
</span></span></code></pre></div><p>The piped which manage your Kubernetes application will be notified by the event, it will create a commit to your application manifest repo, which contains</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-diff" data-lang="diff"><span style="display:flex;"><span> spec:
</span></span><span style="display:flex;"><span> template:
</span></span><span style="display:flex;"><span> spec:
</span></span><span style="display:flex;"><span> containers:
</span></span><span style="display:flex;"><span> - name: helloworld
</span></span><span style="display:flex;"><span><span style="color:#a40000">- image: ghcr.io/pipecd/helloworld:v0.48.0
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#00a000">+ image: ghcr.io/pipecd/helloworld:v0.49.0
</span></span></span></code></pre></div><p>And the piped will trigger a new deployment based on the changed commit.</p>
<p>EventWatcher helps you avoid performance issues as the number of container images you monitor grows. It supports a wide variety of artifact types (Helm charts, Terraform modules, Lambda source zips, etc.) while easily ensuring compatibility with a wide range of CIs.</p>
<h2 id="the-issue-with-eventwatcher">The issue with EventWatcher</h2>
<p>EventWatcher solves the above problems, but it also has certain limitations, although they are not directly due to the design of EventWatcher.</p>
<p>Due to security requirements, projects usually do not store source code and manifests in the same repository, but separate them into two repositories.</p>
<p><img src="https://pipecd.dev/images/code-manifest-repo-separation.png" alt=""></p>
<p>A common request is that when users look at a pipeline deployment on PipeCD, how can they know what source code (code repo) changes are being deployed in this deployment?</p>
<p>If you use container images as an interface between CI and CD, you can take advantage of the LABEL feature of containers to store information about source code commit hashes, branches, etc. The OCI specification also has some predefined LABELs that you can use without defining additional keys.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-dockerfile" data-lang="dockerfile"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">LABEL</span> org.opencontainers.image.source<span style="color:#ce5c00;font-weight:bold">=</span><span style="color:#4e9a06">"https://github.com/pipe-cd/pipecd"</span><span style="color:#a40000">
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#204a87;font-weight:bold">LABEL</span> org.opencontainers.image.revision<span style="color:#ce5c00;font-weight:bold">=</span><span style="color:#4e9a06">"0123456789abcdefg"</span><span style="color:#a40000">
</span></span></span></code></pre></div><p>However, although this approach is similar to the previous one, it is only suitable for artifacts that are container images, and at the same time, scanning container images to get information about commit hashes and displaying it in the UI incurs additional processing overhead.</p>
<p>At this point, we realized a strength in the EventWatcher design: sending events from CI to CD.</p>
<p>The essence of this problem is that when viewing a deployment, you need to know information in the code repository that is only relevant to the manifest repository. In the approach of sending events between CI and CD, you add the necessary information, such as the commit hash and PR URL, as part of the event. When it is piped to create a commit change to the manifest repository, this information is used to link the deployment with the commit trigger and commit the code change.</p>
<p>We use the <a href="https://git-scm.com/docs/git-interpret-trailers">git trailer</a> feature to add this information to the manifest change commit. And finally, wrap up it as <code>--context</code> flag of the pipectl command.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>pipectl event register --name<span style="color:#ce5c00;font-weight:bold">=</span>event-test --data<span style="color:#ce5c00;font-weight:bold">=</span>ghcr.io/pipecd/helloworld:v0.49.0 <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span>--context<span style="color:#ce5c00;font-weight:bold">=</span>Source-Commit-Hash<span style="color:#ce5c00;font-weight:bold">=</span> 6512b1f3fcba7342c11,Source-URL<span style="color:#ce5c00;font-weight:bold">=</span>https://github.com/pipe-cd/pipecd/commit/6512b1f3fcba7342c11,PipeCD-Official-Docs<span style="color:#ce5c00;font-weight:bold">=</span>https://pipecd.dev/
</span></span></code></pre></div><p>If you’re using GitHub as your manifest repo remote storage, you can see it on GitHub UI like this</p>
<p><img src="https://pipecd.dev/images/pipecd-commit-context-github-ui.png" alt=""></p>
<p>With this feature released under <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.49.3">PipeCD v0.49.3</a>, users now can have a link from CD to CI for tracking back which application code change causes this deployment in CD pipeline.</p>
<h2 id="its-good-but-its-not-enough">It’s good, but it’s not enough</h2>
<p>After the release of the EventWatcher update, the community provided positive feedback about resolving the connection issues between CI and CD.
However, we notice some limitations when using PipeCD in very complex projects with many microservices in the same repository.</p>
<p>Each event sent to PipeCD to trigger a deployment can actually be shared to trigger multiple deployments. This is obvious, for example, changes related to protos or common shared libraries, such as logging and metrics libraries, lead to multiple deployments at once.</p>
<p><img src="https://pipecd.dev/images/eventwatcher-trigger-multi-deployments.png" alt=""></p>
<p>This becomes problematic when a development team includes many people working on the same repository and the number of changes affecting many services is large enough: PipeCD’s current UI deployment list makes it difficult to determine exactly which deployments were triggered by which code change.</p>
<p><img src="https://pipecd.dev/images/problematic-deployment-list-ui.jpg" alt=""></p>
<p>Naively, we could just add a <code>root_cause_commit_hash</code> or <code>codebase_commit_hash</code> field to PipeCD’s deployment model and use this information to filter deployments triggered by the same repository code change in the PipeCD UI.</p>
<p>However, if users need to know more than just commit hash, this small change doesn’t reliably achieve the goal. What users really want is a link from the code repository to the manifest repository, that the devs (who know the code change), can use to track which deployments shift those changes to the clusters.</p>
<p>So we looked back at the design of PipeCD and EventWatcher and took the thinking a step further.</p>
<p>We decided to add the concept of Deployment Trace to PipeCD, using the code repository commit hash as the root key. For each code repository commit hash, a Deployment Trace contains the following information:</p>
<ul>
<li>commit_hash: The commit hash of the code repository is used as the key</li>
<li>code repository information: Includes code change author, URL, branches, commit messages, authors, etc.</li>
<li>deployments: A list of deployments triggered by the key commit_hash. Each deployment contains the complete information of the PipeCD deployment (commit, path, pipeline in manifest repository, etc.)</li>
</ul>
<p>This allows users to easily follow the information from the code repository -> manifest repository -> deployment without searching for information step by step. From the perspective of an application engineer making changes to the code repository, it is easy to see which deployment was triggered by a commit, what that deployment was, and how that deployment impacts the service.</p>
<p>We are summarizing <a href="https://github.com/pipe-cd/pipecd/issues/5444">this GitHub issue</a> on the design and implementation of deployment tracing. Feel free to add any idea on the issue.</p>
<h2 id="conclusion">Conclusion</h2>
<p>In this article, we shared the issues we encountered when using PipeCD in a highly complex project, how we solved them through the design and implementation of EventWatcher, and our next steps with deployment tracing.</p>
<p>The deployment tracing feature is planned and will be implemented as soon as possible. It is expected to be released around March 2025.
The PipeCD project is an open-source project; anyone can participate in the development of the project, and we welcome any contributions from the community.</p>
<p>If you have any questions or opinions, feel free to talk in <a href="https://cloud-native.slack.com/">CNCF Slack</a> > #pipecd or <a href="https://docs.google.com/document/d/1AtE0CQYbUV5wLfvAcl9mo9MyTCH52BuU7AngVUvE7vg/edit">PipeCD Community Meeting</a>.</p>
Blog: Overview of the Plan for Pluginnable PipeCD
https://pipecd.dev/blog/2024/11/28/overview-of-the-plan-for-pluginnable-pipecd/
Thu, 28 Nov 2024 00:00:00 +0000https://pipecd.dev/blog/2024/11/28/overview-of-the-plan-for-pluginnable-pipecd/
<p>In this article, we introduce the overview of the “Pluginnable” architecture of PipeCD, a significant progress currently under development.</p>
<p><strong>Note:</strong> The content may be change in the future since it’s still under development.</p>
<h2 id="summary">Summary</h2>
<ul>
<li>In Pluginnable PipeCD, Plugins execute deployments instead of Piped’s core.</li>
<li>Anyone can develop Plugins and <strong>you can use Plugins developed by others</strong>.</li>
<li>It will enable users to deploy to <strong>more various platform</strong> with <strong>more various Stages</strong>.
<ul>
<li>platform example: Cloudflare, Azure, and AWS CloudFormation/CDK</li>
<li>stage example: <a href="https://pipecd.dev/docs/user-guide/managing-application/customizing-deployment/automated-deployment-analysis/">Automated Analysis</a> by New Relic or Amazon CloudWatch</li>
</ul>
</li>
</ul>
<h2 id="whats-pluginnable-pipecd">What’s Pluginnable PipeCD?</h2>
<h3 id="role-of-plugins">Role of Plugins</h3>
<p>In Pluginnable PipeCD, Plugins are actors who execute deployments on behalf of a Piped.</p>
<p><strong>Current: A Piped deploys to each platform by itself</strong>
<img src="https://pipecd.dev/images/plugin-intro-mechanism-cur.drawio.png" alt="h:3.3em w:18em"></p>
<p><strong>In Pluginnable PipeCD: Plugins deploy to each platform</strong></p>
<p>Piped’s core will control deployment flows.</p>
<p><img src="https://pipecd.dev/images/plugin-intro-mechanism-new.drawio.png" alt="h:6.1em w:18em"></p>
<h3 id="where-plugins-come-from">Where Plugins come from?</h3>
<p>Plugins are fetched from outside a Piped. They are not PipeCD built-in code.</p>
<p>Plugin’s binary is placed in GitHub or something, and a Piped loads it on launch.</p>
<p>Configuration would be like this:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Piped's config YAML</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Piped</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">plugin</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># [New Area]</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">k8s_plugin</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># [HERE] (The URL format might be changed)</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">sourceURL</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">https://github.com/xxxx/k8s-plugin</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>The key point is that you can develop your own plugins, or <strong>use plugins developed by others</strong>.</p>
<p>Addiitonally, deployments to Kubernetes, CloudRun, Terraform, ECS, and Lambda, which are currently supported by PipeCD, will be supported as official plugins.</p>
<h3 id="how-does-a-plugin-run">How does a Plugin run?</h3>
<p>A Plugin runs as a gRPC server.
On a Piped starts, the Piped core will load the binary of each specified plugin and launch it as a gRPC server.
While a deployment, a Plugin communicate with Piped core.</p>
<p><img src="https://pipecd.dev/images/plugin-intro-running.drawio.png" alt="h:11em"></p>
<h3 id="how-to-develop-a-plugin">How to develop a Plugin?</h3>
<p><strong>Anyone can develop a Plugin freely.</strong> We will pubilsh a guide on how to develop a Plugin in the future.</p>
<p>Developing a Plugin will not be so tough. Here I introduce somes reasons:</p>
<ul>
<li>
<p>The main task is implementing what you want to execute in each stage.</p>
<ul>
<li>Piped’s core will control deployment flows and handle git. You don’t need to deeply understand the mechanism of GitOps.</li>
<li>To be exact, if you want Plan Preview or Drift Detection for the plugin, you need to implement them.</li>
</ul>
</li>
<li>
<p>Plugins can be also written by languages other than Golang.</p>
</li>
<li>
<p>You don’t need to put your plugin in PipeCD official repository.</p>
<ul>
<li>You can determine review policy and release timing as you want.</li>
</ul>
</li>
</ul>
<h2 id="advantages-of-pluginnable-pipecd">Advantages of Pluginnable PipeCD</h2>
<p>There are three big advantages. Thanks to them, <strong>users will not need to manage additional CD tools</strong> when adding a kind of platform or customizing behaviors.</p>
<h3 id="1-users-can-deploy-to-platforms-other-than-k8scloudrunterraformecslambda">1. Users can deploy to platforms other than K8s/CloudRun/Terraform/ECS/Lambda</h3>
<p>Currently, PipeCD supports deploying to Kubernetes, CloudRun, Terraform, ECS, and Lambda.</p>
<p>Plugins enable you to deploy to the other platforms, for example, Cloudflare, Azure, and Amazon CloudFormation/CDK.</p>
<h3 id="2-users-can-choose-behaviors-as-they-want">2. Users can choose behaviors as they want</h3>
<ul>
<li>Example 1: Deploy in a way different from built-in.</li>
<li>Example 2: For Kubernetes (or any platform), deploy simply for some Applications with Plugin-A, and deploy in a complicated way for the other Applications with Plugin-B.</li>
</ul>
<h3 id="3-users-can-develop-and-use-custom-stages">3. Users can develop and use custom Stages</h3>
<ul>
<li>Example 1: Analyze by New Relic or Amazon CloudWatch in the <code>ANALYSIS</code> stage.</li>
<li>Example 2: Run a Kubernetes Job or a Lambda function to execute a job.</li>
</ul>
<p>These effects will be more powerful as more Plugins come out since you can use plugins made by others.</p>
<h2 id="schedule-overview">Schedule overview</h2>
<p><img src="https://pipecd.dev/images/plugin-intro-schedule.drawio.png" alt=""></p>
<p>Pluginnable PipeCD will be released around Feburary 2025.</p>
<p>The Plugin development guide will be published after March 2025. After that, new Plugins will come out.</p>
<p>For the current PipeCD users, please migrate to the Pluginnable version. New features will be added to the Pluginnable version.
We will share the details of migration ways later. We’ve been making efforts to minimize the amount of the migration tasks. The main tasks will be modifying Piped configs and Application configs.</p>
<h2 id="conclusion">Conclusion</h2>
<p>Pluginnable PipeCD is a big step toward the PipeCD’s vision - “<strong>The One CD for All {applications, platforms, operations}</strong>”. The community energy will be more important.</p>
<p>To see the development progress, visit <a href="https://github.com/pipe-cd/pipecd/blob/master/docs/rfcs/0015-pipecd-plugin-arch-meta.md">the RFC</a> or <a href="https://github.com/pipe-cd/pipecd/issues/5259">the meta Issue</a>.</p>
<p>If you have any questions or opinions, feel free to talk in <a href="https://cloud-native.slack.com/">CNCF Slack</a> > #pipecd or <a href="https://docs.google.com/document/d/1AtE0CQYbUV5wLfvAcl9mo9MyTCH52BuU7AngVUvE7vg/edit">PipeCD Community Meeting</a>.</p>
Blog: Performance improvement in Git operations on PipeCD v0.48.9
https://pipecd.dev/blog/2024/09/11/performance-improvement-in-git-operations-on-pipecd-v0.48.9/
Wed, 11 Sep 2024 00:00:00 +0000https://pipecd.dev/blog/2024/09/11/performance-improvement-in-git-operations-on-pipecd-v0.48.9/
<p>We have implemented performance improvements for Git operations in PipeCD v0.48.9, which was released on September 10, 2024.
In this post, we will explain how we enhanced the performance of Git operations in PipeCD and when you can expect to see these improvements in your daily use.</p>
<h3 id="background">Background</h3>
<p>The PipeCD agent (piped) maintains a git repository cache in the local filesystem to accelerate Git operations.
When piped needs to clone a repository, it first checks if the repository is already cloned in the cache.
If the repository is already cloned, piped will fetch the latest changes from the remote repository.
If the repository is not cloned, piped will clone it from the remote repository.
Piped uses sync.Mutex to ensure that only one goroutine can access the cache at a time.</p>
<h3 id="problem">Problem</h3>
<p>When multiple deployments are triggered simultaneously within a single repository, piped waits for other goroutines to finish their Git operations
because sync.Mutex ensures that only one goroutine can access the cache at a time.
This creates a bottleneck in Git operations, causing delays in deployments.</p>
<h3 id="solution">Solution</h3>
<p>We have improved the performance of Git operations by implementing singleflight.Group from the golang.org/x/sync/singleflight package.
The singleflight.Group is a package for duplicate function call suppression and caching.
It provides a mechanism to suppress duplicate function calls, meaning that if multiple goroutines call the same function with the same key, only one call will be made to the function.
The singleflight.Group also provides a caching mechanism, where the result of the function call is cached and returned to other goroutines that call the same function with the same key.
We use this singleflight.Group to ensure that only one goroutine can clone the repository from the remote repository, while other goroutines wait for the result of the function call.
This makes Git operations faster and more efficient, preventing delays in deployments.</p>
<h3 id="conclusion">Conclusion</h3>
<p>We have enhanced the performance of Git operations in PipeCD v0.48.9 by implementing singleflight.Group from the golang.org/x/sync/singleflight package.
This improvement makes Git operations faster and more efficient, preventing delays in deployments even when multiple deployments are triggered simultaneously within a single repository.
You can expect to experience these improvements in your daily use of PipeCD v0.48.9.</p>
Blog: PipeCD at CNCF KubeCon Hong Kong 2024
https://pipecd.dev/blog/2024/08/09/pipecd-at-cncf-kubecon-hong-kong-2024/
Fri, 09 Aug 2024 00:00:00 +0000https://pipecd.dev/blog/2024/08/09/pipecd-at-cncf-kubecon-hong-kong-2024/
<p><a href="https://events.linuxfoundation.org/kubecon-cloudnativecon-open-source-summit-ai-dev-china/">KubeCon Hong Kong 2024</a> is only two weeks away!
PipeCD team is excited to announce upcoming activities at KubeCon. Let’s come to meet each other and share insights and knowledge 🙌</p>
<h3 id="pipecds-session-with-karmada">PipeCD’s session with Karmada</h3>
<p>We will have a presentation as below.</p>
<ul>
<li>Title: <strong><a href="https://sched.co/1eYYs">Unlocking Scalability and Simplifying Multi-Cloud Management with Karmada and PipeCD</a></strong></li>
<li>Speakers: <a href="https://github.com/khanhtc1202">@khanhtc1202</a>(from PipeCD) and <a href="https://kccncossaidevchn2024.sched.com/speaker/qdurenhongcai?iframe=no">Hongcai Ren</a>(from <a href="https://github.com/karmada-io/karmada">Karmada</a>)</li>
<li>DateTime: Thursday August 22, 2024 11:50 - 12:25 HKT</li>
<li>Venue: Level 1 | Hung Hom Room 7</li>
</ul>
<h3 id="pipecds-booth">PipeCD’s booth</h3>
<p>We will also be around the project booth. Let’s come and discuss!</p>
<p>Booth information:</p>
<!-- TODO: Input the booth info -->
<pre tabindex="0"><code>Project: PipeCDi
Kiosk #: TBA
Kiosk Shift: TBA
Location: TBA
</code></pre><p>That’s all! Have a great KubeCon 🙌</p>
Blog: PipeCD at CNCF KubeCon EU 2024
https://pipecd.dev/blog/2024/03/16/pipecd-at-cncf-kubecon-eu-2024/
Sat, 16 Mar 2024 00:00:00 +0000https://pipecd.dev/blog/2024/03/16/pipecd-at-cncf-kubecon-eu-2024/
<p>KubeCon EU 2024 is only four more weeks away!
PipeCD team is excited to announce upcoming activities at KubeCon. Let’s come to meet each other and share insights and knowledge. We’re excited to see you there 🙌</p>
<h3 id="pipecds-presentations">PipeCD’s presentations</h3>
<p>We will have two presentations at KubeCon EU 2024.</p>
<p>On Tuesday, <a href="https://github.com/khanhtc1202">@khanhtc1202</a> will give <a href="https://sched.co/1aQX4">Effective centric CD pipeline: Toward PipeCD v1.0</a> in the form of a lightning talk.</p>
<p>On Thursday, developer team host a workshop as <a href="https://sched.co/1Yheb">🚨 Contribfest: PipeCD Contribfest</a>, hope to see you guys that time with 💻.</p>
<h3 id="pipecds-booth">PipeCD’s booth</h3>
<p>PipeCD team also be around the project booth, let’s come and discuss.</p>
<p>Booth information</p>
<pre tabindex="0"><code>Project: PipeCD
Kiosk #: PP16-A
Kiosk Shift: Part-time - AM (Fri)
Location: Solutions Showcase | Level 7.2 | Hall 7.2 | Project Pavilion
</code></pre><p>That’s all! Have a great KubeCon 🙌</p>
Blog: Control Plane on local by docker-compose
https://pipecd.dev/blog/2024/03/14/control-plane-on-local-by-docker-compose/
Thu, 14 Mar 2024 00:00:00 +0000https://pipecd.dev/blog/2024/03/14/control-plane-on-local-by-docker-compose/
<p>Currently, you can deploy and operate a PipeCD Control Plane on a Kubernetes cluster or <a href="https://pipecd.dev/blog/2023/02/07/pipecd-best-practice-02-control-plane-on-ecs/">on Amazon ECS</a>.
However, some developers would like to build a Control Plane more easily for introduction or development.
This blog shows you how to install a PipeCD Control Plane on local machine easily.</p>
<p>This blog is for those who would like to:</p>
<ul>
<li>begin using PipeCD and experiment its features instantly, including Control Plane and Piped</li>
</ul>
<h3 id="architecture">Architecture</h3>
<p>The general architecture of PipeCD Control Plane is as below.
<img src="https://pipecd.dev/images/control-plane-components.png" alt=""></p>
<blockquote>
<p>Note: See <a href="https://pipecd.dev/docs/user-guide/managing-controlplane/architecture-overview/">Architecture Overview</a> doc for details.
In this blog, you will build a Control Plane by these containers:</p></blockquote>
<ul>
<li>Server: pipecd server</li>
<li>Ops: pipecd ops</li>
<li>Cache: Redis</li>
<li>Data Store: MySQL</li>
<li>File Store: MinIO</li>
</ul>
<h3 id="installation-of-control-plane">Installation of Control Plane</h3>
<ol>
<li>
<p>Get the demo codes from <a href="https://github.com/pipe-cd/demo/blob/main/control_plane/docker-compose/">https://github.com/pipe-cd/demo/blob/main/control_plane/docker-compose/</a></p>
</li>
<li>
<p>Execute the below command for docker-compose.yaml you got in [1.].</p>
</li>
</ol>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span>docker-compose up
</span></span></code></pre></div><p>After executing the above command, you will see logs like below if success.</p>
<pre tabindex="0"><code class="language-log" data-lang="log">pipecd-server-1 | successfully loaded control-plane configuration
pipecd-server-1 | successfully connected to file store
pipecd-server-1 | successfully connected to data store
pipecd-server-1 | grpc server will be run without tls
pipecd-server-1 | grpc server will be run without tls
pipecd-server-1 | grpc server is running on [::]:9080
pipecd-server-1 | grpc server is running on [::]:9083
pipecd-server-1 | grpc server will be run without tls
pipecd-server-1 | admin server is running on 9085
pipecd-server-1 | grpc server is running on [::]:9081
pipecd-server-1 | start running http server on :9082
</code></pre><h3 id="to-confirm-access-the-console-of-the-control-plane">To confirm: Access the console of the Control Plane</h3>
<ol>
<li>
<p>Access http://localhost:8080 on your web browser.</p>
</li>
<li>
<p>Enter a value as below and <code>CONTINUE</code>.</p>
<ul>
<li><code>Project Name</code>: <code>control-plane-local</code></li>
</ul>
</li>
<li>
<p>Enter values as below and <code>LOGIN</code>.</p>
<ul>
<li><code>Username</code>: <code>hello-pipecd</code></li>
<li><code>Password</code>: <code>hello-pipecd</code></li>
</ul>
</li>
<li>
<p>You will see the applications page. Success!</p>
</li>
</ol>
<p><img src="https://pipecd.dev/images/control-plane-local-console.png" alt=""></p>
<h3 id="clean-up">Clean up</h3>
<p>To clean up the Control Plane, execute the below command.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span>docker-compose down
</span></span></code></pre></div><blockquote>
<p>Note: By following commands instead of above one, you can keep data such as Piped or applications on the Control Plane even after restarting/updating the server component.</p></blockquote>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-sh" data-lang="sh"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Restart only the server component.</span>
</span></span><span style="display:flex;"><span>docker-compose rm -fsv pipecd-server
</span></span><span style="display:flex;"><span>docker-compose up pipecd-server
</span></span></code></pre></div>
Blog: How to set up a local development environment
https://pipecd.dev/blog/2026/01/15/how-to-set-up-a-local-development-environment/
Thu, 15 Jan 2026 00:00:00 +0000https://pipecd.dev/blog/2026/01/15/how-to-set-up-a-local-development-environment/
<h2 id="why-do-you-need-a-local-development-environment">Why do you need a Local Development Environment?</h2>
<p>If you plan to contribute code, fix bugs, or add new plugins to PipeCD, you should run the control plane and Piped agent directly from the source code. This local development setup lets you test your Go changes live before submitting a pull request.</p>
<p>This guide walks through building and running the components from source so you can iterate quickly and confidently.</p>
<p><strong>Estimated setup time: 20–30 minutes</strong></p>
<h2 id="prerequisites">Prerequisites</h2>
<p>Make sure you have the following installed and configured:</p>
<ul>
<li><strong>Go</strong> (v1.21 or higher)</li>
<li><strong>Docker</strong></li>
<li><strong>kubectl</strong></li>
<li><strong>Kind</strong> (required to create the local cluster)</li>
<li><strong>Node.js and Yarn</strong> (required to build the web UI)</li>
<li><strong>A fork of the PipeCD repository</strong></li>
</ul>
<p>To contribute to PipeCD, we recommend setting up a fork:</p>
<ol>
<li>Fork <code>pipe-cd/pipecd</code> on GitHub.</li>
<li>Clone your fork locally:</li>
</ol>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>git clone https://github.com/<YOUR_USERNAME>/pipecd.git
</span></span><span style="display:flex;"><span><span style="color:#204a87">cd</span> pipecd
</span></span></code></pre></div><h2 id="1-prepare-and-start-the-local-cluster">1. Prepare and Start the Local Cluster</h2>
<p>This step prepares a local Kubernetes cluster and container registry required for running the PipeCD control plane locally.</p>
<h3 id="update-dependencies">Update dependencies</h3>
<p>Run these commands to ensure your local Go modules and web dependencies are up to date. Starting the environment may fail if these are outdated.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>make update/go-deps
</span></span><span style="display:flex;"><span>make update/web-deps
</span></span></code></pre></div><h3 id="start-local-registry-and-cluster">Start local registry and cluster</h3>
<p>A helper command starts a local kind cluster and a container registry. This command also automatically creates the <code>pipecd</code> namespace where the components will run.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>make up/local-cluster
</span></span></code></pre></div><p>After the cluster starts, export the kubeconfig to ensure kubectl can communicate with it:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>kind <span style="color:#204a87">export</span> kubeconfig --name pipecd
</span></span></code></pre></div><h2 id="2-run-the-pipecd-control-plane-from-source">2. Run the PipeCD Control Plane (from source)</h2>
<p>The control plane provides the web UI, API, and metadata storage. Running it from source ensures you are testing your latest changes.</p>
<h3 id="start-the-control-plane">Start the control plane</h3>
<p>This command compiles the Go code, builds the web assets, and starts the control plane server locally.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>make run/pipecd
</span></span></code></pre></div><h3 id="access-the-ui">Access the UI</h3>
<p>Once the control plane is running, forward the port to access the UI from your browser. Open a new terminal and run:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>kubectl port-forward -n pipecd svc/pipecd <span style="color:#0000cf;font-weight:bold">8080</span>
</span></span></code></pre></div><p>Then open your browser:</p>
<ul>
<li>URL: <a href="http://localhost:8080?project=quickstart">http://localhost:8080?project=quickstart</a></li>
<li>Username: <code>hello-pipecd</code></li>
<li>Password: <code>hello-pipecd</code></li>
</ul>
<h2 id="3-configure-and-run-the-piped-agent-from-source">3. Configure and Run the Piped Agent (from source)</h2>
<p>The Piped agent connects the control plane to your local Kubernetes cluster. You will run this agent from source as well.</p>
<h3 id="register-piped-in-the-ui">Register Piped in the UI</h3>
<ol>
<li>Go to <strong>Settings → Piped</strong> (or open <a href="http://localhost:8080/settings/piped?project=quickstart">http://localhost:8080/settings/piped?project=quickstart</a>).</li>
<li>Click <strong>+ ADD</strong>, give it a name (for example, <code>dev</code>), and save.</li>
<li><strong>Crucial step:</strong> Copy the generated <strong>Piped ID</strong> and <strong>Base64 encoded key</strong> immediately.</li>
</ol>
<h3 id="create-the-piped-configuration">Create the Piped configuration</h3>
<p>Create a file named <code>piped-config.yaml</code> in your repo root:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Piped</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">projectID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">quickstart</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Replace here with your piped ID.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipedID</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000"><COPIED_PIPED_ID></span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Base64 encoded string of the piped private key.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Replace here with your piped base64 key.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipedKeyData</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000"><COPIED_ENCODED_PIPED_KEY></span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">apiAddress</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">localhost:8080</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">repositories</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">repoId</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">remote</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">[email protected]:pipe-cd/examples.git</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">branch</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">master</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">syncInterval</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">1m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">platformProviders</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example-kubernetes</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KUBERNETES</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Replace here with your kubeconfig absolute file path.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kubeConfigPath</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">/path/to/.kube/config</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h3 id="run-piped-from-source">Run Piped from source</h3>
<p>Use your local code and the config file you just created:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>make run/piped <span style="color:#000">CONFIG_FILE</span><span style="color:#ce5c00;font-weight:bold">=</span>piped-config.yaml <span style="color:#000">INSECURE</span><span style="color:#ce5c00;font-weight:bold">=</span><span style="color:#204a87">true</span>
</span></span></code></pre></div><h2 id="cleaning-up">Cleaning Up</h2>
<p>To stop and remove the local cluster and registry when you are done, run:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span>make down/local-cluster
</span></span></code></pre></div><h2 id="next-steps">Next Steps</h2>
<p>Once Piped starts and shows as connected in the UI, your local development environment is ready. You can now build and test your local changes.</p>
Blog: Terraform Provider for PipeCD is Out!
https://pipecd.dev/blog/2023/07/27/terraform-provider-for-pipecd-is-out/
Thu, 27 Jul 2023 00:00:00 +0000https://pipecd.dev/blog/2023/07/27/terraform-provider-for-pipecd-is-out/
<p>Now PipeCD resources can be managed by Terraform🎉</p>
<p><a href="https://github.com/pipe-cd/terraform-provider-pipecd">terraform-provider-pipecd</a>, which is a Terraform provider for PipeCD, has been released!
Thanks to <a href="https://github.com/arabian9ts">@arabian9ts</a>, <a href="https://twitter.com/kuro_m88">@kurochan</a>, and <a href="https://twitter.com/sivchari">@sivchari</a> for creating this provider!</p>
<p>Until now, there were two methods for adding or updating piped and applications in PipeCD: manually accessing the Control Plane through a browser or using the provided CLI, pipectl. While these methods were intuitive and easy to understand, they had the drawback of being prone to operational errors as the number of managed piped and applications increased. Even incorporating pipectl into shell scripts resulted in a procedural approach. It’s not very cool to have a tool that provides GitOps capabilities but can’t be managed using GitOps principles, right?</p>
<p>The newly released terraform-provider-pipecd addresses these issues. With this provider, you can easily deploy PipeCD resources using the declarative syntax of Terraform.</p>
<p>Using terraform-provider-pipecd, you can enjoy the following benefits:</p>
<ol>
<li><strong>Easy deployment</strong>: It simplifies the process of deploying PipeCD.</li>
<li><strong>Declarative code management</strong>: By managing it as code, you can track changes and reviews through pull requests.</li>
<li><strong>Integration with continuous deployment</strong>: When combined with CI/CD tools, it enables automation of configuration testing and the addition or modification of PipeCD resources.</li>
</ol>
<p>Currently, the PipeCD resources that can be managed with terraform-provider-pipecd are:</p>
<ul>
<li>Piped Agent</li>
<li>Application</li>
</ul>
<p>In the future, based on community demand, more resources that can be managed might be added. Please try out the provider and provide feedback on Github.</p>
<h2 id="how-to-use">How to Use</h2>
<p>While this blog post doesn’t delve into detailed usage, it provides an example of registering a CloudRun Application with PipeCD using HCL code:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-hcl" data-lang="hcl"><span style="display:flex;"><span><span style="color:#a40000">//</span> <span style="color:#204a87;font-weight:bold">Setup</span> <span style="color:#204a87;font-weight:bold">the</span> <span style="color:#204a87;font-weight:bold">provider</span>
</span></span><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">terraform</span> {
</span></span><span style="display:flex;"><span> <span style="color:#204a87;font-weight:bold">required_providers</span> {
</span></span><span style="display:flex;"><span><span style="color:#000"> pipecd</span> <span style="color:#ce5c00;font-weight:bold">=</span> {
</span></span><span style="display:flex;"><span><span style="color:#000"> source</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"pipe-cd/pipecd"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> version</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"0.1.0"</span>
</span></span><span style="display:flex;"><span> }
</span></span><span style="display:flex;"><span> }
</span></span><span style="display:flex;"><span><span style="color:#000"> required_version</span> <span style="color:#ce5c00;font-weight:bold">=</span><span style="color:#000"> "></span><span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#0000cf;font-weight:bold">1</span><span style="color:#000;font-weight:bold">.</span><span style="color:#0000cf;font-weight:bold">4</span><span style="color:#a40000">"</span>
</span></span><span style="display:flex;"><span>}
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#a40000">//</span> <span style="color:#204a87;font-weight:bold">Declaration</span> <span style="color:#204a87;font-weight:bold">of</span> <span style="color:#204a87;font-weight:bold">CloudRun</span> <span style="color:#204a87;font-weight:bold">Application</span>
</span></span><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">resource</span> <span style="color:#4e9a06">"pipecd_application" "main"</span> {
</span></span><span style="display:flex;"><span><span style="color:#000"> kind</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"CLOUDRUN"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> name</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"example-application"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> description</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"This is the simple application"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> platform_provider</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"cloudrun-inproject"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> piped_id</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"your-piped-id"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> git</span> <span style="color:#ce5c00;font-weight:bold">=</span> {
</span></span><span style="display:flex;"><span><span style="color:#000"> repository_id</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"examples"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> remote</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"[email protected]:pipe-cd/examples.git"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> branch</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"master"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> path</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"cloudrun/simple"</span>
</span></span><span style="display:flex;"><span><span style="color:#000"> filename</span> <span style="color:#ce5c00;font-weight:bold">=</span> <span style="color:#4e9a06">"app.pipecd.yaml"</span>
</span></span><span style="display:flex;"><span> }
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div><p>With this simple code, you can define the configuration information for an application. Then, just use the <code>terraform</code> command to perform an <code>apply</code>.</p>
<p>For more details, check out the <a href="https://pipecd.dev/docs/user-guide/terraform-provider-pipecd/">documentation</a> and the <a href="https://github.com/pipe-cd/terraform-provider-pipecd/tree/main/example">example</a> in the repository.</p>
<p>Please watch our Community Meeting #2. <a href="https://github.com/arabian9ts">@arabian9ts</a>, a maintainer of terraform-provider-pipecd explaned how to add an application step by step.</p>
<div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;">
<iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share; fullscreen" loading="eager" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube.com/embed/B8NWgzLNe_o?autoplay=0&controls=1&end=0&loop=0&mute=0&start=0" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" title="YouTube video"></iframe>
</div>
<h2 id="born-in-the-community">Born in the Community</h2>
<p>This project was originally developed by <a href="https://github.com/arabian9ts">@arabian9ts</a>, <a href="https://github.com/kurochan">@kurochan</a>, and <a href="https://github.com/sivchari">@sivchari</a> to make the PipeCD’s management better, and later donated to the pipe-cd organization. Many thanks for their contribution! (And they stay to be the maintainer of the projects to improve it more. How amazing is it?)</p>
<p>PipeCD is supported by the power of such community efforts. We encourage everyone to join the PipeCD community and participate.</p>
Blog: CNCF Sandbox admission 🎉
https://pipecd.dev/blog/2023/05/19/cncf-sandbox-admission/
Fri, 19 May 2023 00:00:00 +0000https://pipecd.dev/blog/2023/05/19/cncf-sandbox-admission/
<p><img src="https://pipecd.dev/images/pipecd-cncf-sandbox.png" alt=""></p>
<p>Today the whole PipeCD team is overjoyed because <strong>the PipeCD project has just been accepted into the <a href="https://www.cncf.io/sandbox-projects/">CNCF Sandbox</a> program!!!</strong> 🥳</p>
<p>This is a great achievement for the whole team and is the beginning of our journey into CNCF. Also, many thanks to the CNCF TOC (Technical Oversight Committee) for the feedback they provided during the project evaluation.</p>
<p>The CNCF Sandbox admission is going to be the cherry on the top of the project milestone, and hope this accelerates further development of the PipeCD project and community.</p>
<p>We are in the middle of the <a href="https://github.com/cncf/toc/issues/1053">onboarding process</a>, and everyone is so excited about that.</p>
<p>Stay tuned for more news and happy PipeCD-ing!!!</p>
Blog: PipeCD best practice 02 - control plane on ECS
https://pipecd.dev/blog/2023/02/07/pipecd-best-practice-02-control-plane-on-ecs/
Tue, 07 Feb 2023 00:00:00 +0000https://pipecd.dev/blog/2023/02/07/pipecd-best-practice-02-control-plane-on-ecs/
<p>This blog is a part of PipeCD best practice series, a guideline for you to operate your own PipeCD.
Currently, you can deploy and operate the PipeCD control plane on a Kubernetes cluster easily, but some developers that would like to introduce PipeCD can not prepare Kubernetes environments. If you have the same problem, this blog is for you. We will show you how to deploy the PipeCD control plane on Amazon ECS.</p>
<h3 id="architecture">Architecture</h3>
<blockquote>
<p>Note: Please refer to <a href="https://pipecd.dev/docs/user-guide/managing-controlplane/architecture-overview/">architecture-overview</a> docs for definitions of PipeCD components such as server, ops, cache, datastore and filestore.</p></blockquote>
<p><img src="https://pipecd.dev/images/control-plane-on-ecs.png" alt=""></p>
<p>Following the above graph for PipeCD control plane runs on Amazon ECS, we have to prepare these next components</p>
<h3 id="secrets-manager">Secrets Manager</h3>
<p>You should put config files (control-plane-config.yaml, envoy-config.yaml) on Secrets Manager because config files contain some credentials such as database passwords.
The examples of config files for ECS are <a href="https://github.com/pipe-cd/control-plane-aws-ecs-terraform-demo/tree/main/config">here</a>. Please edit these files according to your environment.</p>
<pre tabindex="0"><code>aws secretsmanager create-secret --name control-plane-config \
--description "Configuration of control plane" \
--secret-string `base64 control-plane-config.yaml`
aws secretsmanager create-secret --name envoy-config \
--description "Configuration of control plane" \
--secret-string `base64 envoy-config.yaml`
</code></pre><p>You should also put encryption key</p>
<pre tabindex="0"><code>aws secretsmanager create-secret --name encryption-key \
--description "Encryption key for control plane" \
--secret-string `openssl rand 64 | base64`
</code></pre><h3 id="rdsdatastore">RDS(datastore)</h3>
<p>It is possible to use RDS as a datastore. Edit your configuration file for the control plane according to your RDS setting.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">datastore</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">MYSQL</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">url</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">root:password@tcp(endpoint_of_rds:3306) </span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">database</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">quickstart</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h3 id="rediscache">Redis(cache)</h3>
<p>It is possible to use Redis as a cache. Note the endpoint of Redis for the task definition.</p>
<h3 id="s3filestore">S3(filestore)</h3>
<p>It is possible to use S3 as a filestore. The filestore contains state files that describe your secure infrastructure, so make sure to make the bucket private. Only allow pipecd-server(ECS) to access this bucket.</p>
<h3 id="ecs">ECS</h3>
<p>You need to create two different services for pipecd-server and a pipecd-ops because they have the same ports and different permissions. The pipecd-server can be accessed by external clients such as piped or web clients, so this service includes the pipe-cd gateway and this service must be connected to the application loadbalancer. The pipecd-ops can only be accessed by admin users, so this service must only be accessed via SSM session manager.
ECS agent sets config files as environment variables in container from secrets manager. Create configuration files from environment variables in the container as below.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span><span style="color:#204a87">echo</span> <span style="color:#000">$ENVOY_CONFIG</span><span style="color:#000;font-weight:bold">;</span> <span style="color:#204a87">echo</span> <span style="color:#000">$ENVOY_CONFIG</span> <span style="color:#000;font-weight:bold">|</span> base64 -d >> envoy-config.yaml
</span></span></code></pre></div><blockquote>
<p>Note: Attach IAM policy to get secrets from Secrets Manager to task execution role.</p></blockquote>
<blockquote>
<p>Note: If you manage both of RDS and ECS by terraform, you can rewite datastore endpoint in the configuration file.
<code>sed -i -e s/pipecd-mysql/${var.db_instance_address}/ control-plane-config.yaml;</code></p></blockquote>
<blockquote>
<p>Note: Attach IAM policy to access filestore to task role.</p></blockquote>
<h4 id="task-definitions-examples-using-terraform-variables">task definitions examples (using terraform variables)</h4>
<ol>
<li>gateway and server</li>
</ol>
<pre tabindex="0"><code>{
name = "pipecd-gateway"
image = var.gateway_image_url
portMappings = [
{
hostPort = 9090
containerPort = 9090
protocol = "tcp"
}
]
essential = false
command = [
"/bin/sh -c 'echo $ENVOY_CONFIG; echo $ENVOY_CONFIG | base64 -d >> envoy-config.yaml; envoy -c envoy-config.yaml;'"
]
entrypoint = [
"sh",
"-c"
]
secrets = [
{
"name" : "ENVOY_CONFIG",
"valueFrom" : "arn:aws:secretsmanager:${data.aws_region.current.id}:${data.aws_caller_identity.self.account_id}:secret:${var.envoy_config_secret}"
},
]
},
{
name = "pipecd-server"
image = var.server_image_url
portMappings = [
]
command = [
"/bin/sh -c 'echo $CONTROL_PLANE_CONFIG; echo $CONTROL_PLANE_CONFIG | base64 -d >> control-plane-config.yaml; sed -i -e s/pipecd-mysql/${var.db_instance_address}/ control-plane-config.yaml; echo $ENCRYPTION_KEY >> encryption-key; pipecd server --insecure-cookie=true --cache-address=${var.redis_host}:6379 --config-file=control-plane-config.yaml --enable-grpc-reflection=false --encryption-key-file=encryption-key --log-encoding=humanize --metrics=true;'"
]
entrypoint = [
"sh",
"-c"
]
secrets = [
{
"name" : "ENCRYPTION_KEY",
"valueFrom" : "arn:aws:secretsmanager:${data.aws_region.current.id}:${data.aws_caller_identity.self.account_id}:secret:${var.encryption_key_secret}"
},
{
"name" : "CONTROL_PLANE_CONFIG",
"valueFrom" : "arn:aws:secretsmanager:${data.aws_region.current.id}:${data.aws_caller_identity.self.account_id}:secret:${var.control_plane_config_secret}"
},
]
},
</code></pre><ol start="2">
<li>ops</li>
</ol>
<pre tabindex="0"><code>{
name = "pipecd-ops"
image = var.ops_image_url
portMappings = [
{
"name" : "http",
"protocol" : "tcp",
"containerPort" : 9082,
"appProtocol" : "http"
},
{
"name" : "http",
"protocol" : "tcp",
"containerPort" : 9085,
"appProtocol" : "http"
},
]
command = [
"/bin/sh -c 'echo $CONTROL_PLANE_CONFIG; echo $CONTROL_PLANE_CONFIG | base64 -d >> control-plane-config.yaml; sed -i -e s/pipecd-mysql/${var.db_instance_address}/ control-plane-config.yaml; echo $ENCRYPTION_KEY >> encryption-key; pipecd ops --cache-address=${var.redis_host}:6379 --config-file=control-plane-config.yaml --log-encoding=humanize --metrics=true;'"
]
entrypoint = [
"sh",
"-c"
]
secrets = [
{
"name" : "ENCRYPTION_KEY",
"valueFrom" : "arn:aws:secretsmanager:${data.aws_region.current.id}:${data.aws_caller_identity.self.account_id}:secret:${var.encryption_key_secret}"
},
{
"name" : "CONTROL_PLANE_CONFIG",
"valueFrom" : "arn:aws:secretsmanager:${data.aws_region.current.id}:${data.aws_caller_identity.self.account_id}:secret:${var.control_plane_config_secret}"
},
]
},
</code></pre><h3 id="alb">ALB</h3>
<p>You must prepare two target groups for both HTTP and gRPC. Make two hosts and listner rules as below. Listner protocol should be HTTPS becuase it uses gRPC.</p>
<p><img src="https://pipecd.dev/images/control-plane-alb.png" alt=""></p>
<h3 id="terraform-example">Terraform example</h3>
<p>PipeCD gives <a href="https://github.com/pipe-cd/control-plane-aws-ecs-terraform-demo">control-plane-aws-ecs-terraform-demo</a>, which we use Terraform to prepare PipeCD controlplane components and install it on air.</p>
<h4 id="prepare">Prepare</h4>
<ol>
<li>
<p>Prepare SSL certificate
Prepare your domain and SSL certificate from AWS certificate manager.</p>
</li>
<li>
<p>Create a s3 bucket for terraform backend
Write bucket name to <code>00-main.tf</code></p>
</li>
</ol>
<pre tabindex="0"><code>terraform {
backend "s3" {
bucket = "example-pipecd-control-plane-tfstate" #your bucket name for terraform backend
region = "ap-northeast-1"
key = "tfstate"
profile = "pipecd-control-planeg-terraform" #your profile
}
required_providers {
aws = {
version = "~> 3.34.0"
}
}
}
</code></pre><ol start="3">
<li>Edit <code>variables.tf</code> for your project</li>
</ol>
<pre tabindex="0"><code>//export
locals {
alb = {
certificate_arn = ""
}
redis = {
node_type = "cache.t2.micro"
}
rds = {
node_type = "db.t3.micro"
}
ecs = {
memory = "1024"
cpu = "512"
}
}
</code></pre><ol start="4">
<li>Create a S3 bucket for filestore and write the bucket name for it to <code>control-plane-config.yaml</code> and <code>variables.tf</code></li>
</ol>
<pre tabindex="0"><code>apiVersion: "pipecd.dev/v1beta1"
kind: ControlPlane
spec:
datastore:
type: MYSQL
config:
url: sample:test@tcp(pipecd-mysql:3306)
database: quickstart
filestore:
type: S3
config: # edit here
bucket: example-pipecd-control-plane-filestore
region: ap-northeast-1
projects:
- id: quickstart
staticAdmin:
username: hello-pipecd
passwordHash: "$2a$10$ye96mUqUqTnjUqgwQJbJzel/LJibRhUnmzyypACkvrTSnQpVFZ7qK" # bcrypt value of "hello-pipecd"
</code></pre><pre tabindex="0"><code>//export
locals {
s3 = { # These must be unique in the world.
filestore_bucket = "${local.project}-filestore" # edit here
}
}
</code></pre><ol start="5">
<li>Write config of RDS for datastore to <code>control-plane-config.yaml</code>
Note: Do not edit hostname (pipecd-mysql) because it will be edited autimaticaly by terraform.</li>
</ol>
<pre tabindex="0"><code>apiVersion: "pipecd.dev/v1beta1"
kind: ControlPlane
spec:
datastore:
type: MYSQL
config: # edit here
url: sample:test@tcp(pipecd-mysql:3306)
database: quickstart
filestore:
type: S3
config:
bucket: example-pipecd-control-plane-filestore
region: ap-northeast-1
projects:
- id: quickstart
staticAdmin:
username: hello-pipecd
passwordHash: "$2a$10$ye96mUqUqTnjUqgwQJbJzel/LJibRhUnmzyypACkvrTSnQpVFZ7qK" # bcrypt value of "hello-pipecd"
</code></pre><ol start="6">
<li>Put an encryption key and config file in Secrets Manager and write the path to <code>variables.tf</code></li>
</ol>
<pre tabindex="0"><code>locals {
sm = {
control_plane_config_secret = ""
envoy_config_secret = ""
encryption_key_secret = ""
}
}
</code></pre><h4 id="deploy">Deploy</h4>
<pre tabindex="0"><code>terraform apply
</code></pre><h4 id="login-admin-console">login admin console</h4>
<p>You can login pipecd-ops via ECS exec.</p>
<pre tabindex="0"><code>aws ssm start-session --target ecs:${CLUSTER}_${TASK_ID}_${CONTAINER_ID} --document-name AWS-StartPortForwardingSession --parameters '{"portNumber":["9082"],"localPortNumber":["19082"]}'
</code></pre><p>That’s all! Now you have your own PipeCD controlplane and it’s ready to go!!</p>
Blog: May 2022 update
https://pipecd.dev/blog/2022/06/01/may-2022-update/
Wed, 01 Jun 2022 00:00:00 +0000https://pipecd.dev/blog/2022/06/01/may-2022-update/
<p><em>Published by the PipeCD dev team every few months, this update will provide you with news and updates about the project! Please click <a href="https://pipecd.dev/blog/2022/02/10/february-2022-update/">here</a> if you want to see the last status update.</em></p>
<h3 id="whats-changed">What’s changed</h3>
<hr>
<p>It’s been a while from the last update about the development of our PipeCD project, but you can be assured that our PipeCD development is going well. Since the last report, PipeCD team has introduced 5 major releases (from <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.27.0">v0.27.0</a> to the latest <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.32.3">v0.32.3</a>) with several UI improvements and some interesting features that I can’t wait to show you now. This blog post walks you through some notable changes. For all other changes, please check out each release note.</p>
<h4 id="cloud-run-live-state">Cloud Run live state</h4>
<p>Until now, you may notice that only application of kind Kubernetes has a part in its application detail page named live-state which shows you the situation of components of the current running PipeCD application. From version <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.27.0">v0.27.0</a>, we made that feature available for applications of kind Cloud Run too.</p>
<p><img src="https://pipecd.dev/images/cloudrun-live-state.png" alt=""></p>
<h4 id="make-analysis-stage-skippable">Make analysis stage skippable</h4>
<p>One of the outstanding features PipeCD has is <a href="https://pipecd.dev/docs/user-guide/automated-deployment-analysis/">Automated deployment analysis (ADA)</a>, which helps you evaluate the impact of the current deployment right middle its running. Though it’s necessary to have that kind of stage for the stability of your service, sometimes you may want to skip the stage for some kind of quick/hot fixes. In that case, this feature is for you.</p>
<p><img src="https://pipecd.dev/images/analysis-skippable.png" alt=""></p>
<h4 id="enable-to-load-helm-chart-from-oci-registry">Enable to load Helm chart from OCI registry</h4>
<p>With the release of Helm <a href="https://helm.sh/blog/storing-charts-in-oci/">version v3.8.0</a>, Helm is able to store and work with charts in container registries, as an alternative to Helm repositories. PipeCD adopts that feature right a way and for now, you’re able to fetch Helm chart from wherever OCI registries and use it to deploy your services. You can find more about how to use this feature in detail in this <a href="https://pipecd.dev/docs/operator-manual/piped/adding-helm-chart-repository-or-registry/#adding-helm-chart-registry">docs</a>.</p>
<h4 id="the-very-first-touchable-filedb">The very first touchable FileDB</h4>
<blockquote>
<p><strong>⚠️ DEPRECATED NOTICE:</strong> FileDB has been <strong>discontinued</strong> as of PipeCD v0.53.0 due to maintenance complexity and reliability concerns. PipeCD now exclusively supports <strong>Firestore</strong> and <strong>MySQL</strong> as datastore backends.</p></blockquote>
<p>It’s been a while since the first time we made a <a href="https://twitter.com/nghialv2607/status/1480712569535209472">tweet</a> about how PipeCD aims to remove the database as its dependencies to make the installation easier and compact, today we want to make the first achievement on the road to <strong>#nodatabase</strong> world.<br>
For now, you can have a quick shot of using the new FileDB “database” of PipeCD with the quickstart example easily on your local machine by changing the <code>quickstart/control-plane-values.yaml</code> file contains <strong>config.data</strong> section to something like below:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#4e9a06">"pipecd.dev/v1beta1"</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ControlPlane</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">datastore</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type: FILEDB # ⚠️ DEPRECATED</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">Use FIRESTORE or MYSQL instead</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">filestore</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">type</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">MINIO</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">config</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">endpoint</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">http://pipecd-minio:9000</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">bucket</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">quickstart</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">accessKeyFile</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">/etc/pipecd-secret/minio-access-key</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">secretKeyFile</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">/etc/pipecd-secret/minio-secret-key</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">autoCreateBucket</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">true</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">projects</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">id</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">quickstart</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">staticAdmin</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">username</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">hello-pipecd</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">passwordHash</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#4e9a06">"$2a$10$ye96mUqUqTnjUqgwQJbJzel/LJibRhUnmzyypACkvrTSnQpVFZ7qK"</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># bcrypt value of "hello-pipecd"</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Please follow the <a href="https://pipecd.dev/docs/contribution-guidelines/development/#how-to-run-control-plane-locally">development guideline</a> or <a href="https://pipecd.dev/docs/quickstart/">quickstart guideline</a> if you don’t know how to start/install PipeCD control plane on your local machine.</p>
<h4 id="the-pipecd-play-is-available">The PipeCD play is available</h4>
<p>For all users who want to have a glance at how and what PipeCD can give you in real-life usecases, this <a href="https://play.pipecd.dev">PipeCD play environment</a> is for you. We have a blog about that live demo, feel free to check it from <a href="https://pipecd.dev/blog/2022/04/12/the-pipecd-play-environment-is-here/">here</a>.</p>
<p>And many other UI improvements are updated to the PipeCD web console, let’s check it out on our <a href="https://play.pipecd.dev">play environment</a>.</p>
<h3 id="were-opening-more-and-more">We’re opening more and more</h3>
<p>PipeCD is an OSS project! And we want to make not just the source code open, but the whole deployment process should be opened as well in order to get more contribution and support from the open community. We moved almost all of our CI flow to the open Github Actions platform, and as the result, everyone who makes contributions to our PipeCD repository can easily follow/access the CI stages via Github Actions UI. At the time I wrote this blog, PipeCD CI flow had been opened and can be accessed via this <a href="https://github.com/pipe-cd/pipecd/actions">link</a>.</p>
<h3 id="what-are-next">What are next</h3>
<hr>
<p>The team continues actively working on improving the PipeCD product. Besides fixing the reported issues, enhancing the existing features, here are some new features you may catch for few next releases:</p>
<ul>
<li>Piped management via web console: restartable and configuration checkable.</li>
<li>RBAC for PipeCD resources based on the Label mechanism</li>
</ul>
<p>If you have any features want to request or find out a problem, please let us know by creating issues to the <a href="https://github.com/pipe-cd/pipecd/issues">pipe-cd/pipecd</a> repository.</p>
<hr>
<p><em>Follow us on Twitter to keep track of all the latest news: <a href="https://twitter.com/pipecd_dev">https://twitter.com/pipecd_dev</a></em></p>
<p>Happy PipeCD-ing 👋</p>
Blog: The PipeCD play environment is here!!!
https://pipecd.dev/blog/2022/04/12/the-pipecd-play-environment-is-here/
Tue, 12 Apr 2022 00:00:00 +0000https://pipecd.dev/blog/2022/04/12/the-pipecd-play-environment-is-here/
<p>Good news, PipeCD team’s happy to bring you a place where you can have a look at the PipeCD platform in use. We call it the <code>play environment</code> - <a href="https://play.pipecd.dev">https://play.pipecd.dev</a>.</p>
<p><img src="https://pipecd.dev/images/play-environment-overview.png" alt="play-environment-view"></p>
<p style="text-align: center;">
PipeCD play environment view
</p>
<p>With this live demo, you can now have a look at the PipeCD platform in use without self preparing <a href="https://pipecd.dev/docs/quickstart/">quickstart</a> or such. It’s way easier (and faster) to make a try by clicking around and seeing how you can get when using PipeCD as the CD platform on your own.</p>
<h3 id="how-to-access">How to access</h3>
<p>The PipeCD play environment console is available at <a href="https://play.pipecd.dev">https://play.pipecd.dev</a>. After following the link, you will get the login page as below.</p>
<p><img src="https://pipecd.dev/images/play-environment-login.png" alt="play-environment-login"></p>
<p>Type <strong>play</strong> to the input box as the project name to login and click to <code>Continue</code> to go to the account sign in page. Followed by <code>LOGIN WITH GITHUB</code>.</p>
<p><img src="https://pipecd.dev/images/play-environment-github-login.png" alt="play-environment-login-github"></p>
<p>Then, that’s it. Feel free to click around and see what PipeCD can bring to you in real-life use.</p>
<h4 id="some-pages-you-may-feel-interest">Some pages you may feel interest</h4>
<p><img src="https://pipecd.dev/images/play-environment-application.png" alt="play-environment-application"></p>
<p style="text-align: center;">
<a href="https://play.pipecd.dev/applications/913a0bde-1f38-41e3-9f56-75910b8988a9?project=play" target="_blank">Application detail page</a> - show the application's state and info
</p>
<p><img src="https://pipecd.dev/images/play-environment-deployment.png" alt="play-environment-deployment"></p>
<p style="text-align: center;">
<a href="https://play.pipecd.dev/deployments/89c4a27a-a268-448a-bb94-bc994863b695?project=play" target="_blank">Deployment detail page</a> - show the deployment's stages and its log
</p>
<p>You can also have a look at <a href="https://pipecd.dev/docs/user-guide/plan-preview/">PlanPreview</a> feature example, via the play project application configuration repository named <a href="https://github.com/pipe-cd/examples">examples</a> at <a href="https://github.com/pipe-cd/examples/pull/108#issuecomment-1091098475">PR #108 comment</a>.</p>
<p><img src="https://pipecd.dev/images/play-plan-preview.png" alt="play-plan-preview"></p>
<p style="text-align: center;">
Plan preview - give the early feedback by showing the changes which will be applied on PR merged
</p>
<h3 id="notes-for-the-pipecd-play-environment">Notes for the PipeCD play environment</h3>
<ol>
<li>Since the limitation of the resources, you can only log in with the <a href="https://pipecd.dev/docs/operator-manual/control-plane/auth/#role-based-access-control-rbac">Viewer role</a>. This means you can only click around and see PipeCD team prepared examples, <strong>triggering new deployments or creating new resources are disabled</strong>.</li>
<li>Currently, only applications of kinds: <code>KUBERNETES</code>, <code>CLOUDRUN</code> and <code>TERRAFORM</code> are prepared and available to see on the play environment console. We will add example applications of other kinds (<code>LAMBDA</code>, <code>ECS</code>, etc.) later.</li>
<li>The <a href="https://pipecd.dev/docs/user-guide/adding-an-application/">application configuration</a> files for those examples on the play environment are published at <a href="https://github.com/pipe-cd/examples">pipe-cd/examples</a> repository. Those configuration files are <strong>real-life useable</strong> configurations, but only on our cluster, since the encrypted credentials placed in those files are ours. You can replace those and use on your own.</li>
</ol>
<p>Happy PipeCD-ing 👋</p>
Blog: February 2022 update
https://pipecd.dev/blog/2022/02/10/february-2022-update/
Thu, 10 Feb 2022 00:00:00 +0000https://pipecd.dev/blog/2022/02/10/february-2022-update/
<p><em>Published by the PipeCD dev team every month, this update will provide you with news and updates about the project! Please click <a href="https://pipecd.dev/blog/2022/01/05/january-2022-update/">here</a> if you want to see the last status update.</em></p>
<h3 id="whats-changed">What’s changed</h3>
<hr>
<p>Since the last report, PipeCD team has introduced 4 releases (<a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.24.0">v0.24.0</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.24.5">v0.24.5</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.25.0">v0.25.0</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.25.1">v0.25.1</a>). This blog post walks you through their notable changes. For all other changes, please check out each release note.</p>
<h4 id="introducing-label-mechanism">Introducing Label mechanism</h4>
<p>Label concept has been introduced. Labels are key/value pairs that are attached to PipeCD resources such as application, deployment… As a developer, you can use labels to add identifying attributes to them. We believe that supporting the Label will give us more flexibility on grouping, filtering as well as managing access control on PipeCD resources.</p>
<p>Application labels can be specified via the <code>labels</code> field in the application configuration file while deployment labels are inherited from its application.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">prod</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">team</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">product</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>From <code>v0.24.0</code>, application labels are shown on the application list and detail page. All filter forms also have a new label box to allow filtering resources by their labels.</p>
<h4 id="environment-and-deployment-configuration-file-were-deprecated">Environment and Deployment Configuration File were deprecated</h4>
<p>Since the Label was introduced, the Environment becomes a subset of the Label concept. So we decided to deprecate the Environment concept from <code>v0.24.0</code>. Even though it is still displayed on the web console, it will be removed completely from the next release. So make sure to switch to using Label instead.</p>
<p>The deployment configuration file (<code>.pipe.yaml</code>) has been deprecated as well. Please use the application configuration file instead, it has the same format but with some new fields such as <code>name</code>, <code>description</code>, and <code>labels</code>. By using this new config file, all application information can be stored and managed in your Git repository. The new config file also gives PipeCD the ability to detect unregistered applications in Git repository to suggest users to add on the control plane.</p>
<p>Basically, a deployment configuration file can be migrated to be an application configuration file just by adding the <code>name</code> field.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Old deployment configuration file</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># New application configuration file</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">example</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Add this field.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">env</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">prod</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">team</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">product</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>If you are having many applications, you can use this <a href="https://pipecd.dev/docs-v0.25.x/user-guide/command-line-tool/#migrating-deployment-configuration-files-to-application-configuration-files">pipectl command</a> to migrate a bunch of your files seamlessly.</p>
<h4 id="event-list-page-on-web-console">Event list page on web console</h4>
<p>The event concept was designed to help external services such as CI systems to be able to interact with PipeCD. For instance, you can use the <a href="https://pipecd.dev/docs/user-guide/event-watcher/">Event Watcher</a> feature to trigger a new deployment of a given application when a new version of its container image or Helm chart or Terraform package has been just published.</p>
<p>Checking the status of each sent event could be helpful for the developer while troubleshooting, so from <code>v0.25.0</code> that page was added to PipeCD’s web console.</p>
<p><img src="https://pipecd.dev/images/event-list-page.png" alt=""></p>
<h4 id="automated-configuration-drift-detection-for-cloud-run-application">Automated configuration drift detection for Cloud Run application</h4>
<p>Configuration Drift is a phenomenon where running resources of service become more and more different from the definitions in Git as time goes on, due to manual ad-hoc changes and updates. As PipeCD is using Git as a single source of truth, all application resources and infrastructure changes should be done by making a pull request to Git. Whenever a configuration drift occurs it should be notified to the developers and be fixed.</p>
<p>PipeCD includes the Configuration Drift Detection feature, which automatically detects the configuration drift and shows the result in the application details web page as well as sends the notifications to the developers.</p>
<p>Before <code>v0.25.0</code>, this feature could only be used for Kubernetes apps, but now we’re happy to announce that Cloud Run apps can also have that feature.</p>
<p><img src="https://pipecd.dev/images/cloud-run-out-of-sync.png" alt=""></p>
<h3 id="what-are-next">What are next</h3>
<hr>
<p>The team continues actively working on improving the PipeCD product. Besides fixing the reported issues, enhancing the existing features, here are some new features the team is currently working on:</p>
<ul>
<li>Realtime application state for Cloud Run application</li>
<li>RBAC for PipeCD resources based on the Label mechanism</li>
<li>Enable running control-plane without database. It means file storage (such as GCS, S3, Minio) can be used for both data store and file store.</li>
</ul>
<p>If you have any features want to request or find out a problem, please let us know by creating issues to the <a href="https://github.com/pipe-cd/pipecd/issues">pipe-cd/pipecd</a> repository.</p>
<hr>
<p><em>Follow us on Twitter to keep track of all the latest news: <a href="https://twitter.com/pipecd_dev">https://twitter.com/pipecd_dev</a></em></p>
Blog: PipeCD best practice 01 - operate your own PipeCD cluster
https://pipecd.dev/blog/2021/12/29/pipecd-best-practice-01-operate-your-own-pipecd-cluster/
Wed, 29 Dec 2021 00:00:00 +0000https://pipecd.dev/blog/2021/12/29/pipecd-best-practice-01-operate-your-own-pipecd-cluster/
<p>PipeCD is an open source project, you can freely use the released versions of PipeCD to create and operate a continuous delivery system for your service or company. <a href="https://pipecd.dev/docs/quickstart/">Quickstart</a> docs - a complete guide for you to install required components of PipeCD and deploy a simple application via PipeCD is a good point to get started. However, for the sake of the simplicity of that tutorial, some points to keep in mind when operating a PipeCD cluster have been omitted. You will review the PipeCD architecture again and get some tips on how to operate a PipeCD cluster in this post.</p>
<h3 id="again-review-the-pipecd-architecture">Again, review the PipeCD architecture</h3>
<p><img src="https://pipecd.dev/images/architecture-overview-with-roles.png" alt="images"></p>
<p style="text-align: center;">
Component Architecture
</p>
<blockquote>
<p>Note: Please refer to <a href="https://pipecd.dev/docs/concepts/">concepts</a> docs for definitions of PipeCD components such as Control Plane, Piped, Application, etc.</p></blockquote>
<p>At a glance, PipeCD is composed of 2 components, the Control Plane and the Piped(s). As the figure above, depending on your task/role, you need to work with different components of PipeCD.</p>
<ol>
<li>As a operator - platform team, most of your time working with PipeCD is to operate the PipeCD Control Plane. You may also need to cooperate with the product team, helping them install Piped(s) to their applications running cluster depending on your company team’s structure. The space surrounded by a <span style="color: green;">green border</span> shows the operators working area.</li>
<li>As a developer - product team, most of your time working with PipeCD is to deploy, manage and observe your applications via application configuration files and PipeCD web console. You may also need to cooperate with the platform team to install Piped(s) to your applications running cluster if necessary. The space surrounded by a <span style="color: blue;">blue border</span> shows the developers working area.</li>
</ol>
<h3 id="tips-to-operate-pipecd-cluster">Tips to operate PipeCD cluster</h3>
<ol>
<li>
<p>Only a single Control Plane needs to be installed and will be operated by the operators (platform team). The installed Control Plane doesn’t have to be in the same cluster as your applications running cluster or the Piped installed cluster. Just make sure the Piped(s) can connect to the Control Plane via outbound requests is enough.</p>
</li>
<li>
<p>Developers from the product team may need to self-install piped into their applications running cluster if the platform team does not manage those credentials.<br>
<br>
Once the Piped - the runner is installed successfully, developers only need to care about <a href="https://pipecd.dev/docs/user-guide/adding-an-application/">app configuration</a> - which defines the pipeline so that piped(s) can use them to deploy your applications. Interaction with the applications is mainly done via the PipeCD web console and the configuration files stored on Git.</p>
</li>
</ol>
<blockquote>
<p>As an <strong>operator</strong>, PipeCD <a href="https://pipecd.dev/docs/operator-manual/control-plane/">control-plane</a> and <a href="https://pipecd.dev/docs/operator-manual/piped/">piped</a>(s) are what you should care about. As a <strong>developer</strong>, you should care about <a href="https://pipecd.dev/docs/operator-manual/piped/">piped</a> which installed in your applications running cluster and your <a href="https://pipecd.dev/docs/user-guide/adding-an-application/">applications’ PipeCD configurations</a>.</p></blockquote>
<ol start="3">
<li>
<p>It is possible to use a single piped to manage deployments of all the applications to the clusters other than the one in which piped is being installed. However, as security best practices and avoid generating cluster credentials, <strong>we highly recommend running each Piped inside each cluster and that Piped will only manage the applications on that cluster</strong>. In case you want to deploy applications that are required to be installed across clusters/regions/environments, and want to follow this rule of thumb, please refer to the <a href="https://pipecd.dev/docs/user-guide/deployment-chain/">deployment-chain</a> feature.</p>
</li>
<li>
<p>Credentials used by piped(s) while deploying your applications should be managed by the developers of the production team themselves. You can refer to the <a href="https://pipecd.dev/docs/user-guide/secret-management/">secret management</a> feature supported by PipeCD for this purpose.</p>
</li>
</ol>
Blog: January 2022 update
https://pipecd.dev/blog/2022/01/05/january-2022-update/
Wed, 05 Jan 2022 00:00:00 +0000https://pipecd.dev/blog/2022/01/05/january-2022-update/
<p><em>Published by the PipeCD dev team every month, this update will provide you with news and updates about the project! Please click <a href="https://pipecd.dev/blog/2021/11/01/november-2021-update/">here</a> if you want to see the last status update.</em></p>
<h3 id="happy-new-year">Happy New Year</h3>
<hr>
<p>First of all, PipeCD team would like to wish you all a very Happy New Year. 🥳</p>
<p>2021 has been a great year for both PipeCD project and PipeCD team. Many features have been introduced by more than 2000 pull requests from 33 contributors. We would like to thank all those wonderful contributors.</p>
<p><img src="https://pipecd.dev/images/january-2022-contributor-list.png" alt=""></p>
<p>Stepping into 2022, PipeCD team looks forward to contributing even more to make PipeCD project better and more useful for many users in our OSS community.</p>
<h3 id="whats-changed">What’s changed</h3>
<hr>
<p>Since the last report, PipeCD team has introduced 2 releases (<a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.22.0">v0.22.0</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.23.0">v0.23.0</a>). These releases bring many updates to help PipeCD becomes more stable as well as introduce some interesting features. In this blog post, we will recap those new features. For all other changes, please check out each release note to see.</p>
<h4 id="deployment-chain">Deployment chain</h4>
<p>As you know, each application in PipeCD contains a group of resources that are managed together and be deployed to a single cloud provider such as a Kubernetes cluster. The application works independently of each other since there is no connection between them.</p>
<p>But in some use cases, you might want to build a more complex deployment flow where the connection between applications is required. That feature has been requested from a number of PipeCD users.</p>
<p>By <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.23.0">v0.23.0</a>, PipeCD team has brought that feature to reality. It will allow you to roll out applications to multiple clusters/regions gradually or to promote applications across environments. Those deployment strategies can be done simply by specifying a chain of applications in the <code>postSync</code> field of the first application.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">postSync</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">chain</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">applications</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">second-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KUBERNETES</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">third-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">CLOUDRUN</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Currently, in-chain applications can be specified only by <code>name</code>, <code>kind</code> but finding applications by <code>label</code> will also be supported in the near future as well. Since PipeCD is supporting multiple application kinds (such as Kubernetes, Terraform, CloudRun…) so applications from different kinds are allowed to be included in a chain.</p>
<p>For more details, please check out its <a href="https://pipecd.dev/docs/user-guide/deployment-chain/">documentation</a> page.</p>
<h4 id="environment-is-no-longer-required-and-will-be-replaced-by-label">Environment is no longer required and will be replaced by Label</h4>
<p>Environment was changed to be optional while registering Piped or Application. You still can use it from the web console or specify the environment for an application via the <code>envName</code> field in the application configuration file, but we are planning to completely remove the environment concept in the near future. As an alternative, a new <code>Label</code> concept has been introduced, and <code>Environment</code> can be imagined as a particular label.</p>
<p>An application can contain one or more labels in its application configuration file as below:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">TerraformApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">simple-app</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">envName</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">production</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">labels</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic">#env: production</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">service</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">backend</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">...</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><p>Filtering application or deployment by the label is being implemeted currently. We hope that it will be shipped in the next release.</p>
<h4 id="simplifying-the-way-of-registering-an-application">Simplifying the way of registering an application</h4>
<p>Before <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.23.0">v0.23.0</a>, while registering a new application user has to configure the application information manually via a registration form. For now, most of the information can be specified in the application configuration file. And Piped agents automatically find the un-registered applications to suggest to users. It means that all you have to do is just a few clicks on the web console.</p>
<p><img src="https://pipecd.dev/images/legacy-registering-an-application-from-git.png" alt=""></p>
<p style="text-align: center;">
Picking from the suggested application list to register
</p>
<p>Please note that to be suggested, the application configuration file must be suffixed by <code>.pipecd.yaml</code>. And the default name of that file has been changed to <code>app.pipecd.yaml</code> instead of <code>.pipe.yaml</code> as before.</p>
<h4 id="showing-the-connection-status-of-pipeds">Showing the connection status of Pipeds</h4>
<p>The connection status of Piped agents to the control plane is shown on the Settings page in real-time. This gives the operator a quick look at the current status of a particular Piped agent is.</p>
<p><img src="https://pipecd.dev/images/january-2022-piped-connection-status.png" alt=""></p>
<h4 id="more-controls-on-triggering-the-deployment">More controls on triggering the deployment</h4>
<p>By default, when a new merged pull request touches an application, a new deployment for that application will be triggered to execute the sync process.</p>
<p>From <code>v0.22.0</code>, a new <a href="https://pipecd.dev/docs/user-guide/configuration-reference/#deploymenttrigger"><code>trigger</code></a> field has been added to the application configuration file to allow users to customize the triggering condition. For example, using <code>onOutOfSync</code> to enable the ability to attempt to resolve <code>OUT_OF_SYNC</code> state whenever a configuration drift has been detected.</p>
<p>The deployment triggering of each application can be configured with the following fields:</p>
<ul>
<li><code>onCommit</code>: controls triggering new deployment when newly added Git commits touched the application.</li>
<li><code>onCommand</code>: controls triggering new deployment when received a new <code>SYNC</code> command from the web console or <code>pipectl</code></li>
<li><code>onOutOfSync</code>: controls triggering new deployment when application is at <code>OUT_OF_SYNC</code> state. Enabling this will force Piped to always attempt to keep the application as synced as possible.</li>
<li><code>onChain</code>: controls triggering new deployment when the application is counted as a node of a deployment chain. (this configuration is added from <code>v0.23.0</code>)</li>
</ul>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">trigger</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">onCommit</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">disabled</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">false</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">onCommand</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">disabled</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">false</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">onOutOfSync</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">disabled</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">true</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">onChain</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">disabled</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">true</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h3 id="what-are-next">What are next</h3>
<hr>
<p>The team continues actively working on improving the PipeCD product. Besides fixing the reported issues, enhancing the existing features, here are some new features the team is currently working on:</p>
<ul>
<li>Reduce the maintenance cost of the control plane by supporting using file storage (such as GCS, S3, Minio) for both data store and file store. It means <strong>no database</strong> is required to run the control plane.</li>
<li>Automated configuration drift detection for Cloud Run application</li>
</ul>
<p>If you have any features want to request or find out a problem, please let us know by creating issues to the <a href="https://github.com/pipe-cd/pipecd/issues">pipe-cd/pipecd</a> repository.</p>
<hr>
<p><em>Follow us on Twitter to keep track of all the latest news: <a href="https://twitter.com/pipecd_dev">https://twitter.com/pipecd_dev</a></em></p>
Blog: November 2021 update
https://pipecd.dev/blog/2021/11/01/november-2021-update/
Mon, 01 Nov 2021 00:00:00 +0000https://pipecd.dev/blog/2021/11/01/november-2021-update/
<p><em>Published by the PipeCD dev team every month, this update will provide you with news and updates about the project! Please click <a href="https://pipecd.dev/blog/2021/11/01/november-2021-update/">here</a> if you want to see the last status update.</em></p>
<h3 id="whats-changed">What’s changed</h3>
<hr>
<p>Last month, PipeCD team has introduced 4 releases (<a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.20.0">v0.20.0</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.20.1">v0.20.1</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.20.2">v0.20.2</a>, <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.21.0">v0.21.0</a>). Those releases bring many updates to help PipeCD becomes more stable as well as introduce some interesting features. In this blog post, we will recap those new features. For all other changes, please check out each release note to see.</p>
<h4 id="lambda-deployment">Lambda Deployment</h4>
<p>Before <code>v0.20.0</code>, PipeCD only supports deploying an AWS Lambda function by using container image as the input. It means that to run a Lambda function, you have to prepare its container image by building the source code and storing its image in a container registry. That preparation is normally considered as a responsibility of a CI system. That way is straightforward and has been highly recommended recently in the Cloud Native development process.</p>
<p>But to provide more flexibility to the developers, especially those are still not able to apply container technology into their development process. Starting from <code>v0.20.0</code> PipeCD introduces two new ways to deploy an AWS Lambda function: deploying directly from source code stored in Git, deploying a Zip packing code stored in AWS S3.</p>
<ul class="nav nav-tabs" id="tabs-0" role="tablist"><li class="nav-item">
<a class="nav-link active tab-Using-source-code-stored-in-a-Git-repository"
id="tabs-0-0-tab" data-toggle="tab" href="#tabs-0-0" role="tab" onclick="handleClick("Using-source-code-stored-in-a-Git-repository");"
aria-controls="tabs-0-0" aria-selected="true">
Using source code stored in a Git repository
</a>
</li><li class="nav-item">
<a class="nav-link tab-Using-Zip-of-source-code-stored-in-S3"
id="tabs-0-1-tab" data-toggle="tab" href="#tabs-0-1" role="tab" onclick="handleClick("Using-Zip-of-source-code-stored-in-S3");"
aria-controls="tabs-0-1" aria-selected="false">
Using Zip of source code stored in S3
</a>
</li><li class="nav-item">
<a class="nav-link tab-Using-container-image"
id="tabs-0-2-tab" data-toggle="tab" href="#tabs-0-2" role="tab" onclick="handleClick("Using-container-image");"
aria-controls="tabs-0-2" aria-selected="false">
Using container image
</a>
</li></ul>
<div class="tab-content" id="tabs-0-content"><div class="tab-pane fade show active"
id="tabs-0-0" role="tabpanel" aria-labelled-by="tabs-0-0-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Deploy Lambda function directly from source code stored in a Git repository.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">LambdaFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">SimpleFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">source</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">git</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">[email protected]:username/lambda-function-code.git</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">ref</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">v1.0.0</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">path</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">hello-world</span></span></span></code></pre></div></div>
<div class="tab-pane fade"
id="tabs-0-1" role="tabpanel" aria-labelled-by="tabs-0-1-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Deploy Lambda function by a Zip packing source code stored in S3.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">LambdaFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">SimpleFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">s3Bucket</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd-sample-lambda</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">s3Key</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd-sample-src</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">s3ObjectVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">1pTK9_v0Kd7I8Sk4n6abzCL</span></span></span></code></pre></div></div>
<div class="tab-pane fade"
id="tabs-0-2" role="tabpanel" aria-labelled-by="tabs-0-2-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># Deploy Lambda function by using a container image.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">LambdaFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">SimpleFunction</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">image</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ecr.ap-northeast-1.amazonaws.com/lambda-test:v0.0.1</span></span></span></code></pre></div></div>
</div>
<p>Check out its <a href="https://pipecd.dev/docs/user-guide/configuring-deployment/lambda">documentation</a> for more details.</p>
<h4 id="automated-deployment-analysis-ada">Automated Deployment Analysis (ADA)</h4>
<p>ADA is a good way to automate the process of evaluating the impact of a deployment during its lifetime to help building a robust release process. Any application can be configured to analyze its deployments based on its metrics data, log messages, or results from directly emitting requests to the application.</p>
<p>Until now, PipeCD has been providing a way to allow the developer to configure a list of <code>query</code> and <code>threshold</code> to analyze metrics data of a running deployment. Any query that returns a result exceeding the given threshold will cause the deployment to be failed, and a rollback stage will be executed if needed. Although this way is relatively straightforward, there is a challenge you can see here; it isn’t easy to find an appropriate threshold value to use since software is constantly changing time over time that making those values could be changed dynamically. Therefore, some new analysis strategies <code>PREVIOUS</code>, <code>CANARY_BASELINE</code>, <code>CANARY_PRIMARY</code> have been introduced since <code>v0.20.0</code>. They allow analyzing without requiring any threshold values.</p>
<p>Sum up, you can choose one of the following four strategies which fits your use case:</p>
<ul>
<li><code>PREVIOUS</code>: A method to compare the time series of metrics data between the running and the last successful deployment</li>
<li><code>CANARY_BASELINE</code>: A method to compare the time series of metrics data between the Canary and Baseline variants</li>
<li><code>CANARY_PRIMARY</code>: A method to compare the time series of metrics data between the Canary and Primary variants</li>
<li><code>THRESHOLD</code>: A method to check the given queries againts the given thresholds</li>
</ul>
<ul class="nav nav-tabs" id="tabs-1" role="tablist"><li class="nav-item">
<a class="nav-link active tab-Using-PREVIOUS-strategy"
id="tabs-1-0-tab" data-toggle="tab" href="#tabs-1-0" role="tab" onclick="handleClick("Using-PREVIOUS-strategy");"
aria-controls="tabs-1-0" aria-selected="true">
Using PREVIOUS strategy
</a>
</li><li class="nav-item">
<a class="nav-link tab-Using-CANARY_BASELINE-strategy"
id="tabs-1-1-tab" data-toggle="tab" href="#tabs-1-1" role="tab" onclick="handleClick("Using-CANARY_BASELINE-strategy");"
aria-controls="tabs-1-1" aria-selected="false">
Using CANARY_BASELINE strategy
</a>
</li><li class="nav-item">
<a class="nav-link tab-Using-THRESHOLD-strategy"
id="tabs-1-2-tab" data-toggle="tab" href="#tabs-1-2" role="tab" onclick="handleClick("Using-THRESHOLD-strategy");"
aria-controls="tabs-1-2" aria-selected="false">
Using THRESHOLD strategy
</a>
</li></ul>
<div class="tab-content" id="tabs-1-content"><div class="tab-pane fade show active"
id="tabs-1-0" role="tabpanel" aria-labelled-by="tabs-1-0-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># ADA by comparing the time series of metrics data between the running and the last successful deployment.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ANALYSIS</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">metrics</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">strategy</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">PREVIOUS</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">provider</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">my-prometheus</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">deviation</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">HIGH</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">interval</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">5m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">query</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">sum (rate(http_requests_total{status=~"5.*"}[5m])) / sum (rate(http_requests_total[5m]))</span></span></span></code></pre></div></div>
<div class="tab-pane fade"
id="tabs-1-1" role="tabpanel" aria-labelled-by="tabs-1-1-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># ADA by comparing the time series of metrics data between the Canary and Baseline variants.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ANALYSIS</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">metrics</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">strategy</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">CANARY_BASELINE</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">provider</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">my-prometheus</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">deviation</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">HIGH</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">interval</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">5m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">query</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">sum (rate(http_requests_total{job="foo-{{ .Variant.Name }}", status=~"5.*"}[5m])) / sum (rate(http_requests_total{job="foo-{{ .Variant.Name }}"}[5m]))</span></span></span></code></pre></div></div>
<div class="tab-pane fade"
id="tabs-1-2" role="tabpanel" aria-labelled-by="tabs-1-2-tab"><div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#8f5902;font-style:italic"># ADA by checking the given queries againts the given thresholds.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">ANALYSIS</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">with</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">duration</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">30m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">metrics</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">strategy</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">THRESHOLD</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">provider</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">my-prometheus</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">interval</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">5m</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">expected</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">max</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#0000cf;font-weight:bold">0.01</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">query</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">sum (rate(http_requests_total{status=~"5.*"}[5m])) / sum (rate(http_requests_total[5m]))</span></span></span></code></pre></div></div>
</div>
<p>Check out its <a href="https://pipecd.dev/docs/user-guide/automated-deployment-analysis/#strategies">documentation</a> for more details.</p>
<h4 id="notification">Notification</h4>
<p>Any PipeCD event (deployment triggered, planned, analysis completed…) can be configured to send to external services like Slack or a Webhook service. While forwarding those events to a chat service helps developers have a quick and convenient way to know the deployment’s current status, forwarding to a Webhook service may be useful for triggering other related tasks.</p>
<p>Until now, only Slack has been supported. From <code>v0.21.0</code> you can configure your Pipeds to send its events to external services via Webhook. See <a href="https://pipecd.dev/docs/operator-manual/piped/configuring-notifications/#sending-notifications-to-external-services-via-webhook">here</a> to know how to configure.</p>
<p>Besides that, events sent to Slack can be configured to mention one or multiple Slack users. It would be helpful to prevent developers from missing important events.</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-yaml" data-lang="yaml"><span style="display:flex;"><span><span style="color:#204a87;font-weight:bold">apiVersion</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">pipecd.dev/v1beta1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">kind</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">KubernetesApp</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"></span><span style="color:#204a87;font-weight:bold">spec</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">pipeline</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">stages</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_CANARY_ROLLOUT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">WAIT_APPROVAL</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_PRIMARY_ROLLOUT</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">name</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">K8S_CANARY_CLEAN</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">notification</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">mentions</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">event</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#000">DEPLOYMENT_WAIT_APPROVAL</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">slack</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#000">slack-user-id-1</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#000">slack-user-id-2</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#204a87;font-weight:bold">event</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#4e9a06">"*"</span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#8f5902;font-style:italic"># Specifying "*" means mentioning the given users for all events.</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span><span style="color:#204a87;font-weight:bold">slack</span><span style="color:#000;font-weight:bold">:</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span><span style="display:flex;"><span><span style="color:#f8f8f8;text-decoration:underline"> </span>- <span style="color:#000">slack-user-id-3</span><span style="color:#f8f8f8;text-decoration:underline">
</span></span></span></code></pre></div><h4 id="piped-operation">Piped Operation</h4>
<p>As you know, PipeCD is designed with <code>control-plane</code> and <code>agent</code> model (see <a href="https://pipecd.dev/docs/overview/">component architecture diagram</a>). Piped is a single binary agent you run in your cluster, your local network to handle the deployment tasks related to that cluster. It can be run as a Pod inside a Kubernetes cluster, as a process in a virtual machine, or even on your local machine. Piped is stateless so that it can be restarted without worrying about data loss. That helps the product team reduce the cost of maintaining their Pipeds. You can see those <a href="https://pipecd.dev/docs/operator-manual/piped/installation/">installation guides</a> to know how to install Piped on each environment.</p>
<p>From <code>v0.20.0</code>, managing Piped has become even easier than ever. With <a href="https://pipecd.dev/docs/operator-manual/piped/remote-upgrade-remote-config/#remote-upgrade">Remote-Upgrade</a> feature, you can restart the currently running Piped with another version from the web console. And with <a href="https://pipecd.dev/docs/operator-manual/piped/remote-upgrade-remote-config/#remote-upgrade">Remote-Config</a> feature, you can enforce your Piped to use the latest config data just by updating its config file stored in a remote location such as a Git repository.</p>
<p><img src="https://pipecd.dev/images/settings-remote-upgrade.png" alt=""></p>
<p style="text-align: center;">
Select a list of Pipeds to upgrade from Settings page
</p>
<h3 id="talks">Talks</h3>
<hr>
<p>Two members from PipeCD team did talk about PipeCD at some local events in Japan.</p>
<ul>
<li>
<p>2021/10/08 - Introducing PipeCD as a unified CD system for both infrastructure and application</p>
<p><em>Cloud Native Developers JP, by <a href="https://twitter.com/nghialv2607">@nghialv</a> (Youtube <a href="https://www.youtube.com/watch?v=hobyQUD2Z8c">video</a> in Japanese)</em></p>
</li>
<li>
<p>2021/10/29 - How to deploy AWS application with GitOps style by PipeCD</p>
<p><em>JAWS-UG コンテナ支部, by <a href="https://twitter.com/khanhtc1202">@khanhtc</a> (Youtube <a href="https://www.youtube.com/watch?v=CQ_XppWnLyg">video</a> in Japanese)</em></p>
</li>
</ul>
<h3 id="what-are-next">What are next</h3>
<hr>
<p>The team continues actively working on improving PipeCD product. Besides fixing the reported issues, enhancing the existing features, here are some new features the team is currently working on:</p>
<ul>
<li>Deployment Chain - Allow rolling out to multiple clusters gradually or promoting across environments</li>
<li>Resource Tagging - A better way to group and filter PipeCD resources such as applications, deployments</li>
</ul>
<p>If you have any features want to request or find out a problem, please let us know by creating issues to the <a href="https://github.com/pipe-cd/pipecd/issues">pipe-cd/pipecd</a> repository.</p>
<hr>
<p><em>Follow us on Twitter to keep track of all the latest news: <a href="https://twitter.com/pipecd_dev">https://twitter.com/pipecd_dev</a></em></p>
Blog: Migrate Control Plane datastore to MySQL
https://pipecd.dev/blog/2021/04/01/migrate-control-plane-datastore-to-mysql/
Thu, 01 Apr 2021 00:00:00 +0000https://pipecd.dev/blog/2021/04/01/migrate-control-plane-datastore-to-mysql/
<p>Since PipeCD release <a href="https://pipecd.dev/blog/2021/03/25/release-v0.9.8">v0.9.8</a> which introduces MySQL as PipeCD control-plane datastore, we plan to drop the support for MongoDB datastore in the near future.
Consider the supports of cloud providers (GCP, AWS, Azure, etc), MySQL has a higher status over MongoDB is one of the most reasons for this support-dropping conclusion.</p>
<p>If you are using MongoDB as your PipeCD control-plane datastore, the following guide is manipulation to migrate your datastore to MySQL.</p>
<h3 id="before-start">Before start</h3>
<p>You need to install the <a href="https://pipecd.dev/docs/user-guide/command-line-tool/#installation">pipectl</a> version <a href="https://github.com/pipe-cd/pipecd/releases/tag/v0.9.10-1-4ab28c0">v0.9.10-1-4ab28c0</a> command-line tool.</p>
<p>Validate your installed <code>pipectl</code> command</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-console" data-lang="console"><span style="display:flex;"><span><span style="color:#8f5902">$</span> pipectl datastore -h
</span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic">Manage control-plane datastore resource.
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"></span><span style="color:#a40000">
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#000;font-style:italic">Usage:
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> pipectl datastore [command]
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"></span><span style="color:#a40000">
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#000;font-style:italic">Available Commands:
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> migrate Migrate data to MySQL datastore.
</span></span></span></code></pre></div><h3 id="migration">Migration</h3>
<p>Step by step guide for migration</p>
<h4 id="1-prepare-your-mysql-datastore-instance">1. Prepare your MySQL datastore instance.</h4>
<p>Note:</p>
<ul>
<li><strong>MySQL v8.0 or later is required</strong>.</li>
<li>To enable <code>pipectl</code> to migrate data to the new MySQL datastore, your new MySQL data instance has to be connected from <code>pipectl</code> running environment.<br>
The current implementation of <code>pipectl datastore</code> subcommand connects directly to datastore, you do not need to authenticate your <code>pipectl</code> binary with <code>API Key</code> as for other subcommands. Just make sure <code>pipectl</code> running environment is in the same network with your MySQL instance is enough.</li>
<li>Your MySQL instance has to be initialized with the going to be used <code>database</code>, make sure you create it before move to the next step.</li>
</ul>
<p>For example, if you use docker to create your new MySQL instance, the command should be</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-console" data-lang="console"><span style="display:flex;"><span><span style="color:#8f5902">$</span> docker run -d <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span><span style="color:#000;font-style:italic"> --name test-db \
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> -e MYSQL_ROOT_PASSWORD=XXX \
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> -e MYSQL_DATABASE=*database-name* \
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> mysql:8.0
</span></span></span></code></pre></div><h4 id="2-stop-pipecd-control-plane">2. Stop PipeCD control-plane</h4>
<p>In case your PipeCD control-plane is installed by <code>helm</code>, simply run <code>helm uninstall</code> command would help.</p>
<h4 id="3-migrate-using-pipectl">3. Migrate using <code>pipectl</code></h4>
<p>Migrate using the following command (replace <code>upstream-data-src</code>, <code>downstream-data-src</code> and <code>database</code> with your corresponding values)</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-console" data-lang="console"><span style="display:flex;"><span><span style="color:#8f5902">$</span> pipectl datastore migrate <span style="color:#4e9a06">\
</span></span></span><span style="display:flex;"><span><span style="color:#4e9a06"></span><span style="color:#000;font-style:italic"> --upstream-data-src="mongodb://127.0.0.1:27017/quickstart" \
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> --downstream-data-src="root:test@tcp(127.0.0.1:3306)" \
</span></span></span><span style="display:flex;"><span><span style="color:#000;font-style:italic"> --database=quickstart
</span></span></span></code></pre></div><p>Note:</p>
<ul>
<li>Make sure your <code>data-src</code>s value are formatted as same as the above example.</li>
<li>If you want to migrate only specific data models (not all at once), use the <code>--models</code> flag as follow <code>--models=Application,Project</code>. (Use <code>pipectl datastore migrate -h</code> to get the list of migratable models)</li>
</ul>
<h4 id="4-start-pipecd-control-plane-with-the-new-configuration">4. Start PipeCD control-plane with the new configuration</h4>
<p>Your new control-plane’s configuration should be updated as follow:</p>
<div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-diff" data-lang="diff"><span style="display:flex;"><span> apiVersion: "pipecd.dev/v1beta1"
</span></span><span style="display:flex;"><span> kind: ControlPlane
</span></span><span style="display:flex;"><span> spec:
</span></span><span style="display:flex;"><span> datastore:
</span></span><span style="display:flex;"><span><span style="color:#a40000">- type: MONGODB
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#00a000">+ type: MYSQL
</span></span></span><span style="display:flex;"><span><span style="color:#00a000"></span> config:
</span></span><span style="display:flex;"><span><span style="color:#a40000">- url: mongodb://127.0.0.1:27017/quickstart
</span></span></span><span style="display:flex;"><span><span style="color:#a40000"></span><span style="color:#00a000">+ url: root:test@tcp(127.0.0.1:3306)
</span></span></span><span style="display:flex;"><span><span style="color:#00a000"></span> database: quickstart
</span></span><span style="display:flex;"><span>...
</span></span></code></pre></div><p>See <a href="https://pipecd.dev/docs/operator-manual/control-plane/configuration-reference/">ConfigurationReference</a> for the full configuration.</p>
<p>Restart PipeCD control-plane as same as you start it before, your PipeCD should be ready 🚀.</p>
Blog: Announcing PipeCD
https://pipecd.dev/blog/2020/10/06/announcing-pipecd/
Tue, 06 Oct 2020 00:00:00 +0000https://pipecd.dev/blog/2020/10/06/announcing-pipecd/
<p>Today we are excited to announce the open-source availability of PipeCD: a continuous delivery system for declarative Kubernetes, Serverless, and Infrastructure applications.
PipeCD aims to provide a unified CD solution for multiple application kinds on multi-cloud that empowers engineers to deploy faster with more confidence.
It is also available as a GitOps tool that enables doing deployment operations by pull request on Git.</p>
<br>
<p><img src="https://pipecd.dev/images/deployment-details.png" alt=""></p>
<p style="text-align: center;">
Deployment Details Page
</p>
<br>
<h3 id="background">Background</h3>
<p>As one of our Developer Productivity team’s missions, we aim to empower engineers to deploy their services faster, more frequently with reliability.
Martin Fowler, in his book <em>Continuous Delivery</em>, points out that “The biggest risk to any software effort is that you end up building something that isn’t useful. The earlier and more frequently you get working software in front of real users, the quicker you get feedback to find out how valuable it really is.”</p>
<p>Recently, with the popularity of cloud services and the container technology, engineers have even more options in choosing the infrastructure model, the cloud services, which are most suitable for their team’s requirements.
At <a href="https://www.cyberagent.co.jp/en/">CyberAgent</a>, we have a large number of services from many teams where each team can have a different infrastructure model and a different cloud service. Some big projects also deploy their services on multi-cloud.
This diversification leads to a problem that we are facing, lacking a robust CD system for all teams.</p>
<p>So we decided to create a new CD system that provides a unified interface for many application kinds to improve the developer experience.</p>
<h3 id="key-features">Key Features</h3>
<p>While designing PipeCD, we focused on the following <a href="https://pipecd.dev">4 key features</a> with the aim of creating a CD system that provides a good experience for both developers and operators.</p>
<p><strong>Visibility</strong></p>
<p>Visibility is one of the most requested factors we received when surveying engineers in our company.
Visibility is the ability to see what’s going on in the cluster, the ability to see how each component of the application had been deployed, the ability to know quickly why the deployment was failed.
Visibility for a team leader is the ability to know the delivery performance of the team and what metrics should be improved.
With PipeCD, we always strive to maximize the visibility for engineers, operators as well as team leaders. Currently, it includes:</p>
<ul>
<li>Deployment pipeline UI shows clarify what is happening</li>
<li>Separate logs viewer for each individual deployment</li>
<li>Realtime visualization of application component and state</li>
<li>Deployment notifications to slack, webhook endpoints</li>
<li>Insights show the delivery performance</li>
</ul>
<p>In addition, the entire state of the service is managed through Git, so you can view the whole state of the cluster and all audit logs provided by Git.</p>
<p><strong>Automation</strong></p>
<p>Automation reduces or removes repetitive overhead of frequent releases. So maximizing automation helps to minimize human error during the deployment process, as well as reduce the amount of work engineers need to do.
PipeCD has the following automated functionalities:</p>
<ul>
<li>Automated deployment analysis based on metrics, logs, emitted requests</li>
<li>Automatically roll back to the previous state as soon as analysis or a pipeline stage fails</li>
<li>Automatically detect configuration drift to notify and render the changes</li>
<li>Automatically watch and detect the new container images to deploy</li>
</ul>
<p><strong>Secure</strong></p>
<p>The CD system often carries a lot of credentials needed to access the cluster and the necessary services of the teams.
Ensuring the safety of the teams is always on our top priority.
So while designing the PipeCD, we decided not to store those credentials in a central place. Instead of that, all user’s credentials always stay inside their clusters.</p>
<ul>
<li>Support single sign-on and role-based access control</li>
<li>Credentials are not exposed outside the cluster and not saved in the control-plane</li>
<li>Piped makes only outbound requests and can run inside a restricted network</li>
</ul>
<p><strong>Multi-provider & Multi-Tenancy</strong></p>
<p>Multi-provider means supporting multiple cloud services, multiple container registries, multiple monitoring services for doing deployment analysis.
You can use PipeCD to deploy your Kubernetes applications, CloudRun, AWS Lambda application and Terraform application.
It also supports doing progressive delivery with canary and blue-green strategy.</p>
<ul>
<li>Easy to operate multi-cluster, multi-tenancy by separating control-plane and piped</li>
<li>Support multiple analysis providers including Prometheus, Datadog, Stackdriver, and more</li>
<li>Support multiple application kinds on multi-cloud including Kubernetes, Terraform, Cloud Run, AWS Lambda</li>
</ul>
<br>
<p>While designing PipeCD, we simplified its architecture by minimizing the number of components, so you do not have to install many things to enable all features.
In addition, PipeCD also supports storing data in several fully-managed services to minimize the operating cost.</p>
<p>Currently, we have completed the basic features and many of the features are in the alpha status. We are working hard to increase the stability and planning to release a stable version in the next months.</p>
<h3 id="community">Community</h3>
<p>PipeCD team hopes to receive a warm welcome and feedback from the open-source community.
We value every contribution and invite you to join us on GitHub, Slack and Twitter.</p>
<ul>
<li>Visit our website and documentation at <a href="https://pipecd.dev">https://pipecd.dev</a></li>
<li>Check out the code at <a href="https://github.com/pipe-cd/pipecd">https://github.com/pipe-cd/pipecd</a> or explore the <a href="https://pipecd.dev/docs/examples/">examples</a></li>
<li>Join us on Slack <a href="https://slack.cncf.io">@cloud-native/pipecd</a> to chat with other developers</li>
<li>Follow us on Twitter <a href="https://twitter.com/pipecd_dev">@pipecd_dev</a> to get the latest news</li>
</ul>
<p>PipeCD team is hiring engineers/interns to work on PipeCD. Please contact us if you are interested.</p>
<h3 id="thanks">Thanks</h3>
<p>Finally, we would like to thank the existing open-source CD projects like Spinnaker, FluxCD, ArgoCD… PipeCD has been built on many great ideas from those great projects.
PipeCD team would also like to thank CyberAgent’s engineers and collaborators from other companies, who have sent us so much valuable feedback throughout the development process to this day.</p>