SPEC: Rails App Autostaging

Goal

Be able to push-button deploy an app to a cloud-based staging environment that may or may not already exist in a predictable fashion.

How I’ll do it

  • Set up a cloud-based staging environment and take notes on what I have to change beyond the basic provisioned OS (OpenSUSE Leap 42.1)
  • Make cap tasks to deploy the app to the existing staging environment
  • Make cap tasks to verify the status of the staging environment (not running, running but needs cold deploy, warm deploy)
  • Automate staging setup in a cloud-init script
  • Make cap tasks to create a new staging environment

I’ll know it’s done when

  • I can type cap staging deploy with no staging environment and see the staging environment be created and the app be deployed
  • I can type cap staging deploy again and see a warm deploy to the existing environment
  • I can destroy the staging environment, then type cap staging create_environment and see the new environment be created
  • I can type cap staging deploy and deploy to the fresh environment

I’ll need to verify

  • Dev environment is up to date
  • App is healthy
    • All specs run clean
    • All automated tests run successfully
  • Cloud account is healthy and can allocate resources via API/CLI

I’ll need to learn or relearn



blog comments powered by Disqus

Published

01 January 2017

Category

hacking