Travis

Hephy Deployment

This page documents deployments using dpl v1 which is currently the legacy version. The dpl v2 is released, and we recommend useig it. Please see our blog post for details. dpl v2 documentation can be found here.

Travis CI supports uploading to Hephy.

A minimal configuration is:

deploy:
  provider: hephy
  controller: hephy.hephyapps.com
  username: "Hephy User Name"
  password: "Hephy Password"
  app: App_name
  cli_version: vX.Y.Z  # e.g. v2.7.0 being the latest at this time

It is recommended that you encrypt your password. Assuming you have the Travis CI command line client installed, you can do it like this:

$ travis encrypt "YOUR HEPHY PASSWORD" --add deploy.password

You will be prompted to enter your api key on the command line.

You can also have the travis tool set up everything for you:

$ travis setup hephy

Keep in mind that the above command has to run in your project directory, so it can modify the .travis.yml for you.

Conditional Releases #

You can deploy only when certain conditions are met. See Conditional Releases with on:.

The .gitignore method #

As this deployment strategy relies on git, be mindful that the deployment will honor .gitignore.

If your .gitignore file matches something that your build creates, use before_deploy to change its content.

Run Commands Before or After Deploy #

Sometimes, you want to run commands before or after triggering a deployment. You can use the before_deploy and after_deploy stages for this. These will only be triggered if Travis CI is actually pushing a release.

    before_deploy: "echo 'ready?'"
    deploy:
      ..
    after_deploy:
      - ./after_deploy_1.sh
      - ./after_deploy_2.sh