Skip to content

Just Run Tests

Just Run Tests #27

Workflow file for this run

name: List running service versions on ${{ inputs.environment }}

Check failure on line 1 in .github/workflows/just-run-tests.yml

View workflow run for this annotation

GitHub Actions / List running service versions on ${{ inputs.environment }}

Invalid workflow file

The workflow is not valid. .github/workflows/just-run-tests.yml (Line: 1, Col: 7): Unrecognized named-value: 'inputs'. Located at position 1 within expression: inputs.environment
on:
# Only runs manually
workflow_dispatch:
inputs:
environment:
description: Which AWS Account to use
type: choice
required: true
options:
- dev
- test
- uat
- prod
jobs:
list-versions:
permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout
runs-on: ubuntu-latest
environment: ${{ inputs.environment }}
steps:
- name: Git clone the repository
uses: actions/checkout@v4
- name: Get current date
shell: bash
id: currentdatetime
run: echo "datetime=$(date +'%Y%m%d%H%M%S')" >> $GITHUB_OUTPUT
- name: configure aws credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::${{ secrets.AWS_ACCOUNT }}:role/GithubCopilotDeploy
role-session-name: "${{ inputs.app_name }}_${{ inputs.environemnt }}_copilot_${{ steps.currentdatetime.outputs.datetime }}"
aws-region: eu-west-2
- name: Install AWS Copilot CLI
shell: bash
run: |
curl -Lo aws-copilot https://github.com/aws/copilot-cli/releases/latest/download/copilot-linux && chmod +x aws-copilot && sudo mv aws-copilot /usr/local/bin/copilot
- name: confirm copilot env
shell: bash
run: |
if [ $(copilot env ls) != "${{ inputs.environment }}" ]; then
echo $(copilot env ls)
exit 1
fi
- name: List running versions
run: |
scripts/list-versions.sh