github-actions

Setup Environment Variables

Purpose

Sometimes we will want to have common environment variables across a number of workflows, these are not secret, but can handle things like colours and titles. To maintain consistancy and allow commonality of code it is desirable to have one location for these variables.

Input Parameters

Caution

The environment variables are only set for the specific JOB and will need to be set on each job that uses them

Example

See Example Workflow

  - name: Check out the repo
    uses: actions/checkout@v2

  - name: set-up-environment
    uses: DFE-Digital/github-actions/set-up-environment@master             
                    
  - name: Print
    run:  |
          echo "URL                   = $"
          echo "APPLICATION           = $"
          echo "DOCKERHUB_REPOSITORY  = $"
          echo "DOMAIN                = $"
          echo "PAAS_APPLICATION_NAME = $"
          echo "SLACK_FAILURE         = $"
          echo "SLACK_SUCCESS         = $"