<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>PipeCD – Creating a Plugin</title>
    <link>https://pipecd.dev/docs-v1.0.x/plugins/creating-a-plugin/</link>
    <description>Recent content in Creating a Plugin on PipeCD</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    
	  <atom:link href="https://pipecd.dev/docs-v1.0.x/plugins/creating-a-plugin/index.xml" rel="self" type="application/rss+xml" />
    
    
      
        
      
    
    
    <item>
      <title>Docs-V1.0.x: Introduction</title>
      <link>https://pipecd.dev/docs-v1.0.x/plugins/creating-a-plugin/chapter-01-introduction/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      
      <guid>https://pipecd.dev/docs-v1.0.x/plugins/creating-a-plugin/chapter-01-introduction/</guid>
      <description>
        
        
        &lt;p&gt;You start with an empty directory and finish with a simple plugin that &lt;code&gt;piped&lt;/code&gt; can load and run.&lt;/p&gt;
&lt;h2 id=&#34;what-you-build&#34;&gt;What you build&lt;/h2&gt;
&lt;p&gt;The plugin copies a directory of files from a Git repository onto the machine where &lt;code&gt;piped&lt;/code&gt; runs. This is a common way to deploy to virtual machines and bare-metal hosts.&lt;/p&gt;
&lt;p&gt;The plugin implements two deployment stages:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;FILE_DIFF&lt;/code&gt; compares the files in the Git repository against the files already on the machine and prints the difference to the deployment log, without changing anything.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;FILE_SYNC&lt;/code&gt; applies the change. It copies the files that exist in the Git repository and removes any files on the machine that are no longer in Git.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The plugin stays small and uses only the Go standard library and the plugin SDK.&lt;/p&gt;
&lt;h2 id=&#34;before-you-start&#34;&gt;Before you start&lt;/h2&gt;
&lt;p&gt;You should be comfortable with Go and know basic gRPC, since a plugin runs as a gRPC server that &lt;code&gt;piped&lt;/code&gt; talks to. You do not need to know PipeCD&amp;rsquo;s internals. If you are new to plugins, read the &lt;a href=&#34;https://pipecd.dev/docs-v1.0.x/concepts/#plugins&#34;&gt;Plugins concepts&lt;/a&gt; first and then the &lt;a href=&#34;https://pipecd.dev/blog/2024/11/28/overview-of-the-plan-for-pluginnable-pipecd/&#34;&gt;plugin architecture blog&lt;/a&gt; which explains the design.&lt;/p&gt;
&lt;h2 id=&#34;how-the-chapters-fit-together&#34;&gt;How the chapters fit together&lt;/h2&gt;
&lt;p&gt;Each chapter builds on the previous one:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Chapters 2 and 3 set up the project and define the configuration types.&lt;/li&gt;
&lt;li&gt;Chapters 4 and 5 implement the methods that plan a deployment.&lt;/li&gt;
&lt;li&gt;Chapters 6 and 7 implement the methods that run each stage.&lt;/li&gt;
&lt;li&gt;Chapters 8 and 9 connect the plugin to &lt;code&gt;piped&lt;/code&gt;, run it, and cover where to go next.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;a-note-on-versions&#34;&gt;A note on versions&lt;/h2&gt;
&lt;p&gt;The plugin SDK (&lt;a href=&#34;https://pkg.go.dev/github.com/pipe-cd/piped-plugin-sdk-go&#34;&gt;&lt;code&gt;github.com/pipe-cd/piped-plugin-sdk-go&lt;/code&gt;&lt;/a&gt;) still changes between releases. The code here tracks the SDK version this documentation targets. If a snippet does not compile, trust the &lt;a href=&#34;https://github.com/pipe-cd/pipecd&#34;&gt;&lt;code&gt;pipecd&lt;/code&gt;&lt;/a&gt; source and SDK reference over the text.&lt;/p&gt;

      </description>
    </item>
    
  </channel>
</rss>
