Skip to content

Commit

Permalink
Create release.yml
Browse files Browse the repository at this point in the history
Add release to testing
  • Loading branch information
sfawcett123 authored May 15, 2020
1 parent d429977 commit 749fe05
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@

name: Release to test
on:
release:
types: [edited, created]
env:
DOCKERHUB_REPOSITORY: dfedigital/get-teacher-training-adviser-service
GOVUKPAAS_ORG: dfe-teacher-services
GOVUKPAAS_SPACE: get-into-teaching-test
CONTAINER: get-teacher-training-adviser-service-test

jobs:
deploy:
name: Deploy to GovUK PaaS Test Environment
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v2
- name: Download CloudFoundry CLI
run: wget -O /tmp/cf-cli.deb "https://packages.cloudfoundry.org/stable?release=debian64&source=github"
- name: Install CloudFoundry CLI
run: sudo dpkg -i /tmp/cf-cli.deb
- name: Check CloudFoundry CLI version
run: cf --version
- name: Login to PaaS
run: cf login -a api.london.cloud.service.gov.uk -u "${{ secrets.GOVUKPAAS_USERNAME }}" -p "${{ secrets.GOVUKPAAS_PASSWORD }}" -o $GOVUKPAAS_ORG -s $GOVUKPAAS_SPACE
- name: Current Org and Space
run: cf target
- name: Deploy Built Image
run: cf push $CONTAINER --docker-image $DOCKERHUB_REPOSITORY:sha-$(git rev-parse --short $GITHUB_SHA)

0 comments on commit 749fe05

Please sign in to comment.