Skip to content

Update requriements #620

Update requriements

Update requriements #620

Workflow file for this run

name: gsy-e-sdk-CI
on:
pull_request
jobs:
build:
runs-on: ubuntu-20.04
strategy:
matrix:
python: [3.8]
steps:
- uses: actions/checkout@v2
- uses: 8BitJonny/[email protected]
id: PR
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
sha: ${{ github.event.pull_request.head.sha }}
filterOutClosed: true
- name: Parse integration tests branch
env:
prBody: ${{ steps.PR.outputs.pr_body }}
run: |
echo "::set-output name=PARSED_INTEGRATION_TESTS_BRANCH::$(echo -e $prBody | sed -n 's/.*\*\*INTEGRATION_TESTS_BRANCH\*\*=\([^ ]*\).*/\1/p')"
id: parse_integration_tests_branch
- name: Parse gsy-e image target branch
env:
prBody: ${{ steps.PR.outputs.pr_body }}
run: |
echo "::set-output name=PARSED_GSY_E_TARGET_BRANCH::$(echo -e $prBody | sed -n 's/.*\*\*GSY_E_TARGET_BRANCH\*\*=\([^ ]*\).*/\1/p')"
id: parse_gsye_target_branch
- name: Validate parsed integration tests branch
env:
PARSED_INTEGRATION_TESTS_BRANCH: ${{ steps.parse_integration_tests_branch.outputs.PARSED_INTEGRATION_TESTS_BRANCH }}
run: |
echo "::set-output name=INTEGRATION_TESTS_BRANCH::${PARSED_INTEGRATION_TESTS_BRANCH:-master}"
id: validated_integration_tests_branch
- name: Validate parsed gsy-e target branch
env:
PARSED_GSY_E_TARGET_BRANCH: ${{ steps.parse_gsye_target_branch.outputs.PARSED_GSY_E_TARGET_BRANCH }}
run: |
echo "::set-output name=GSY_E_TARGET_BRANCH::${PARSED_GSY_E_TARGET_BRANCH:-master}"
id: validated_gsye_target_branch
- name: parse framework branch
env:
prBody: ${{ steps.PR.outputs.pr_body }}
run: |
echo "::set-output name=PARSED_GSY_FRAMEWORK_BRANCH::$(echo -e $prBody | sed -n 's/.*\*\*GSY_FRAMEWORK_BRANCH\*\*=\([^ ]*\).*/\1/p')"
id: parse_branch_framework
- name: validate parsed framework branch
env:
PARSED_GSY_FRAMEWORK_BRANCH: ${{ steps.parse_branch_framework.outputs.PARSED_GSY_FRAMEWORK_BRANCH }}
run: |
echo "::set-output name=GSY_FRAMEWORK_BRANCH::${PARSED_GSY_FRAMEWORK_BRANCH:-master}"
id: validated_branch_framework
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python }}
- name: Install Tox
run: pip install tox==3.24.4
- name: install docker-compose
run: |
sudo curl -L https://github.com/docker/compose/releases/download/v2.2.3/docker-compose-linux-x86_64 -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
- name: Run Tox
run: tox -e $TOXENV
env:
TOXENV: ci
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
INTEGRATION_TESTS_REPO: https://gsydev:${{ secrets.GSYDEV_TOKEN }}@github.com/gridsingularity/gsy-backend-integration-tests.git
INTEGRATION_TESTS_BRANCH: ${{ steps.validated_integration_tests_branch.outputs.INTEGRATION_TESTS_BRANCH }}
GSY_E_TARGET_BRANCH: ${{ steps.validated_gsye_target_branch.outputs.GSY_E_TARGET_BRANCH }}
GSY_FRAMEWORK_BRANCH: ${{ steps.validated_branch_framework.outputs.GSY_FRAMEWORK_BRANCH }}