Getting Started

In this guide you will learn how to install Armory Spinnaker on AWS. You will learn how to configure Spinnaker so that you can use it to deploy your applications to any environment safely and securely.

As you go through this guide, keep in mind that there are four major milestones:

  • Installing Spinnaker
  • Re-deploying Spinnaker
  • Deploying an Application
  • Production Readiness

Spinnaker’s Workflow

Before we dive in, it is important to understand the workflow that Spinnaker prefers. This will allow us to understand what we need to install and configure and why. Let’s go over it from beginning to end. The process starts with a code change and ends with that code running in production. The general case is:

  1. A change is made to master in your code repository.
  2. The build system creates an artifact.
  3. The build system pushes that artifact to a central artifact repository or registry.
  4. This causes a deploy pipeline to trigger within Spinnaker.
  5. Spinnaker downloads the artifact from the central artifact repository or registry.
  6. (Optional) Spinnaker creates an image from the artifact.
  7. Spinnaker deploys the image to an environment.

For example, suppose you are using GitHub, Jenkins, Artifactory and AWS. Then a deployment workflow might look like:

  1. A change is made to master in your code repository.
  2. Jenkins creates a deb package from the code in the GitHub repo.
  3. Jenkins archives the deb package and uploads it to Artifactory.
  4. Spinnaker triggers a pipeline based on the Jenkins job completing.
  5. Spinnaker downloads the artifact from Artifactory.
  6. Spinnaker creates an AMI with the artifact and its dependencies.
  7. Spinnaker deploys the AMI to an environment.

Milestones

The following steps are broken up into milestones. However, you should follow them serially.

Installing Armory Spinnaker

Install Armory Spinnaker
The first goal is to get Spinnaker installed and running to the point where we can connect to its UI.

On install, Armory Spinnaker is configured to be in HA mode.

Tips during configuration:

  • Scale down Spinnaker to be just 1 instance.
    Click on nonpolling server group and go to Server Group Actions > Resize gif

  • Change the Auto Scaling Group Healthcheck from ELB to EC2. This will allow you to restart Armory Spinnaker without the ASG terminating the instance.
    Click on the remaining ASG and go to Advance Settings > Edit Advance Settings gif

Start by SSH’ing to the single instance of Armory Spinnaker. Throughout this guide you will be making changes to the *-local.yml files in /opt/spinnaker/config/. In order for the changes to take affect you will need to restart Armory Spinnaker. To restart run the following:

$ sudo service armory-spinnaker stop && sleep 15 && sudo service armory-spinnaker start  # restart spinnaker

It will take a moment for the services to come back online. You can check its status by running:

$ watch curl http://localhost:5000/healthcheck

Then ctrl+c to exit watch once it is healthy.

Re-Deploying Spinnaker

Next we will configure Spinnaker so that Spinnaker can re-deploy Spinnaker. This way we can make configuration changes and provide Spinnaker with an upgrade path.

We will do the following:

Deploying An Application

After we have Spinnaker in a re-deployable state we can get started on deploying an application.

We will do the following:

Production Ready

Before opening Spinnaker up for general availability within your organization, there are several concerns to address.

We will do the following:

Finally we can undo some shortcuts when we were configuring Spinnaker. Just undo everything in the Tips during configurations Guide

Next Steps

Optionally, you may want to:

Once you have Spinnaker production ready, it is time to onboard users. You may want to:

  • Make Packer scripts to help migrate from Chef, Puppet or Salt.
  • Share the User Guides
  • Provide example pipelines that are specific to your organization