<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Spinnaker – Development Environment</title>
    <link>https://deploy-preview-629--spinnaker-io.netlify.app/docs/community/contributing/code/developer-guides/dev-env/</link>
    <description>Recent content in Development Environment on Spinnaker</description>
    <generator>Hugo -- gohugo.io</generator>
    
	  <atom:link href="https://deploy-preview-629--spinnaker-io.netlify.app/docs/community/contributing/code/developer-guides/dev-env/index.xml" rel="self" type="application/rss+xml" />
    
    
      
        
      
    
    
    <item>
      <title>Docs: Getting Set Up for Spinnaker Development</title>
      <link>https://deploy-preview-629--spinnaker-io.netlify.app/docs/community/contributing/code/developer-guides/dev-env/getting-set-up/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      
      <guid>https://deploy-preview-629--spinnaker-io.netlify.app/docs/community/contributing/code/developer-guides/dev-env/getting-set-up/</guid>
      <description>
        
        
        &lt;h2 id=&#34;overview&#34;&gt;Overview&lt;/h2&gt;
&lt;p&gt;This page describes the steps a Developer should take to fetch Spinnaker&amp;rsquo;s codebase and get set up to work on it.&lt;/p&gt;
&lt;p&gt;Follow the 
&lt;a href=&#34;https://deploy-preview-629--spinnaker-io.netlify.app/community/contributing/code/submitting/&#34;&gt;contributing guidelines&lt;/a&gt;

if you plan to submit your work as a patch to the open source project.&lt;/p&gt;
&lt;h2 id=&#34;system-requirements&#34;&gt;System Requirements&lt;/h2&gt;
&lt;p&gt;This guide assumes you have access to a machine with a minimum specification of:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;At least 16 GB of RAM&lt;/li&gt;
&lt;li&gt;At least 6 cores CPU&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;macos&#34;&gt;MacOS&lt;/h3&gt;
&lt;p&gt;These are some tools but install additional as needed the tools for your needs&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;homebrew: Not required but useful - 
&lt;a href=&#34;https://brew.sh/&#34; target=&#34;_blank&#34;&gt;can be installed via here&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Docker: either docker desktop or rancher. CAUTION:  Spinnaker uses TestContainers heavily and you&amp;rsquo;ll potentially need
to adjust settings for test containers which is out of the scope of this guide.&lt;/li&gt;
&lt;li&gt;git: Installed usually via Xcode Command Line Tools - often by trying to run git from a terminal&lt;/li&gt;
&lt;li&gt;curl: &lt;code&gt;brew install curl&lt;/code&gt; - not required explicitly but useful for testing&lt;/li&gt;
&lt;li&gt;JDK 17: A JDK is required since we&amp;rsquo;re building from source.  This can be done using 
&lt;a href=&#34;https://sdkman.io/&#34; target=&#34;_blank&#34;&gt;sdkman&lt;/a&gt;
 or any other installation tool.&lt;/li&gt;
&lt;li&gt;node/npm: (version &amp;gt;=16)&lt;/li&gt;
&lt;li&gt;yarn: &lt;code&gt;npm install -g yarn&lt;/code&gt; or 
&lt;a href=&#34;https://yarnpkg.com/lang/en/docs/install/&#34; target=&#34;_blank&#34;&gt;guide&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;mysql: &lt;code&gt;docker run -e MYSQL_ROOT_PASSWORD=changeit -it --rm mysql:8 --verbose&lt;/code&gt; is a good basic example but will need the databases configured as documented in the 
&lt;a href=&#34;https://deploy-preview-629--spinnaker-io.netlify.app/docs/setup/install/storage/&#34;&gt;storage configuration&lt;/a&gt;
.  Adjust the docker command to persist if you want to keep your data between runs.&lt;/li&gt;
&lt;li&gt;redis: &lt;code&gt;docker run -d --rm --name redis -p 0.0.0.0:6379:6739 valkey/valkey:8&lt;/code&gt; as an example.&lt;/li&gt;
&lt;li&gt;
&lt;a href=&#34;https://deploy-preview-629--spinnaker-io.netlify.app/docs/setup/install/providers/&#34;&gt;Set up your cloud provider of choice&lt;/a&gt;
.  Locally these providers would be added to &lt;code&gt;~/.spinnaker/clouddriver-local.yml&lt;/code&gt; files&lt;/li&gt;
&lt;li&gt;Add the other sql/redis/other configuration to your &lt;code&gt;~/.spinnaker/*.yml&lt;/code&gt; files for development&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Next, clone the 
&lt;a href=&#34;https://github.com/spinnaker/spinnaker&#34; target=&#34;_blank&#34;&gt;spinnaker monorepo&lt;/a&gt;
.  You can now start spinnaker assuming you&amp;rsquo;ve configured the necessary settings locally for sql/redis.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#204a87&#34;&gt;cd&lt;/span&gt; spinnaker
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;./gradlew run
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This starts up &lt;em&gt;ALL&lt;/em&gt; the spinnaker services service via a single gradle task.  Services can be started independently as needed.  Keep in mind that there is a dependency
tree for services that will mean that things won&amp;rsquo;t start unless a dependent service is up and running.  Front50 is a common base service dependency for all the other
spinnaker services.&lt;/p&gt;
&lt;h2 id=&#34;making-changes-to-spinnaker&#34;&gt;Making Changes to Spinnaker&lt;/h2&gt;
&lt;p&gt;Once you have a working LocalGit deployment you can begin to make changes to the codebase.
After you&amp;rsquo;ve made edits in the code of a service you can see those changes reflected
by restarting the services as needed.&lt;/p&gt;
&lt;h2 id=&#34;configuring-an-ide&#34;&gt;Configuring an IDE&lt;/h2&gt;
&lt;h3 id=&#34;intellij&#34;&gt;IntelliJ&lt;/h3&gt;
&lt;p&gt;Import the project into IntelliJ:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Select &lt;code&gt;New&lt;/code&gt; &amp;gt; &lt;code&gt;Project from Existing Sources&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Navigating to the &lt;code&gt;build.gradle&lt;/code&gt; file (i.e., &lt;code&gt;~/dev/spinnaker/build.gradle&lt;/code&gt;)&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id=&#34;debugging&#34;&gt;Debugging&lt;/h2&gt;
&lt;p&gt;Each Java service can be configured to listen for a debugger. To start the JVM in debug
mode, set the Java system property &lt;code&gt;DEBUG=true&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The JVM will then listen for a debugger to be attached on a port specific to that service. The
service-specific debug ports are as follows:&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;Service&lt;/th&gt;
&lt;th style=&#34;text-align:left&#34;&gt;Port&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Gate&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8184&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Orca&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8183&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Clouddriver&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;7102&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Front50&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8180&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Rosco&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8187&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Igor&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8188&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;Echo&lt;/td&gt;
&lt;td style=&#34;text-align:left&#34;&gt;8189&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;The JVM will not wait for the debugger to be attached before starting a service; the relevant
JVM arguments can be seen and modified as needed in the service&amp;rsquo;s &lt;code&gt;build.gradle&lt;/code&gt; file.&lt;/p&gt;
&lt;h2 id=&#34;next-steps&#34;&gt;Next steps&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;If you haven&amp;rsquo;t done so already, read through the

&lt;a href=&#34;https://deploy-preview-629--spinnaker-io.netlify.app/docs/reference/architecture/&#34;&gt;Spinnaker Architecture reference&lt;/a&gt;
 to learn more about the individual
services&amp;rsquo; responsibilities, their dependencies on each other, and their port mappings.&lt;/li&gt;
&lt;li&gt;Consider working on one of the

&lt;a href=&#34;https://github.com/spinnaker/spinnaker/issues?utf8=%E2%9C%93&amp;amp;q=is%3Aissue&amp;#43;is%3Aopen&amp;#43;label%3A%22beginner&amp;#43;friendly%22&#34; target=&#34;_blank&#34;&gt;issues marked &amp;amp;ldquo;beginner-friendly&amp;amp;rdquo;&lt;/a&gt;

to start learning and contributing to Spinnaker right away.&lt;/li&gt;
&lt;li&gt;
&lt;a href=&#34;https://join.slack.com/t/spinnakerteam/shared_invite/zt-3f4dqg66a-hX~tWeWPL3Sfnj3F8Ie2xg&#34; target=&#34;_blank&#34;&gt;Sign up for Spinnaker&amp;amp;rsquo;s Slack community&lt;/a&gt;
 and join the 
&lt;a href=&#34;https://spinnakerteam.slack.com/messages/C0DPVDMQE/&#34; target=&#34;_blank&#34;&gt;#dev&lt;/a&gt;
 channel to ask questions and get feedback while developing Spinnaker.&lt;/li&gt;
&lt;li&gt;Read through the 
&lt;a href=&#34;../extending/new-stage&#34;&gt;New Stage guide&lt;/a&gt;
 to add new stages and steps&lt;/li&gt;
&lt;li&gt;Read about extending spinnaker 
&lt;a href=&#34;../extending/crd-extensions&#34;&gt;with CRD handling&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

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