Webmaker/Deployment

From MozillaWiki
Jump to: navigation, search

Deploying apps on webmaker.org

Deploying apps to webmaker.org is relatively painless, involving the following steps:

  1. Increment package.json and tag a new version automatically by checking out the master branch, updating it to current master (git pull mozilla master after changing branches) and running npm version patch. This will both update the package.json version and create a git tag of the form "v1.2.3"
  2. Push this new commit to the mozilla/master repo ("mozilla" represents the upstream repo name here, if you use a different name, make sure to use that in the following command, too). This is done by running git push mozilla master --tags to push both the new commit and the new tag.
  3. Start a jenkins build. This is done by:
    1. Visiting http://jenkins.mofoprod.net:8080/
    2. logging in (get a user account if you don't have one by asking JP)
    3. visiting the project page for the thing you want to build
    4. click the "Build now" button on the left sidebar
    5. Fill in the tag you want to build. If the npm version patch generated "v1.2.3", for instance, then fill in "v1.2.3".
    6. Hit the build button. You are now done.
  4. If your update requires any configuration changes (a new parameter, or you need to change an existing one) ask any of the webmaker team members with S3 access to update those values for you.
  5. When building the app for staging, the app will (typically) be deployed on [app].mofostaging.net
  6. When building the app for deployment, the app will (typically) be deployed on [app].webmaker.org
  7. You can verify the deployment succeeded outside of Jenkins by visiting the deployed app's website and checking the output for the /healthcheck URL, which should tell you the app version (and possibly additional module information)

Note that some apps automatically build themselves to their staging location if code is merged into the development branch. Right now those are Popcorn and Appmaker. These only require building if you need to update the production versions.