STNG-165 Run one scenario in AWS dev fully end-to-end #55
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to AWS | |
on: | |
push: | |
branches: ["dev"] | |
pull_request: # TODO: REMOVE THESE 2 LINES WHEN IT WORKS, BEFORE MERGING TO DEV. | |
types: [ opened, synchronize, reopened ] | |
env: | |
AWS_REGION: "eu-north-1" | |
NG_CLI_ANALYTICS: "ci" | |
AWS_ENVIRONMENT: "dev" | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ env.AWS_ENVIRONMENT }} | |
# Enforces only AWS env name matching branches are checkout and deployed. | |
- name: Print commit sha | |
shell: bash | |
env: | |
COMMIT_SHA: ${{ github.event.pull_request.head.sha }} | |
run: | | |
echo "sha: $COMMIT_SHA" | |
- name: Set up Java JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '21' | |
cache: 'maven' | |
- name: Set up Node.js 22.x | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 22 | |
cache: 'npm' | |
cache-dependency-path: webui/package-lock.json | |
- name: Build Conformance-Gateway | |
run: | | |
mvn clean package -B -V -DskipTests | |
# No need to run tests, as they are already run in the PR workflow | |
- name: Verify Run in AWS | |
env: | |
TEST_LOGIN_EMAIL: ${{ secrets.AWS_DEV_LOGIN_EMAIL }} # User account details to log in the Web UI. | |
TEST_LOGIN_PASSWORD: ${{ secrets.AWS_DEV_LOGIN_PASSWORD }} | |
TEST_LOGIN_URL: ${{ secrets.AWS_DEV_WEB_URL }} | |
run: | | |
mvn test -B -Djunit.includedTags=Integration -Djunit.excludedTags=WebUI |