Skip to content

Commit

Permalink
Merge branch 'openSourcePPaaS' into openSourcePPaaSScripting
Browse files Browse the repository at this point in the history
  • Loading branch information
tkmcmaster committed Sep 14, 2023
2 parents 657296d + 4c4a907 commit 15675e2
Showing 1 changed file with 20 additions and 13 deletions.
33 changes: 20 additions & 13 deletions .github/workflows/pr-ppaas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,24 +62,31 @@ jobs:
cd $CONFIG_WASM_LIB_DIR
wasm-pack build --release -t nodejs --scope fs
- name: Create .env file for controller that can be overridden by a .env.production file
run: |
set -x
# setup some envs to various paths that re required for build
PROJECT_ROOT=$PWD
CONTROLLER_DIR=$(realpath $PROJECT_ROOT/controller)
# .env.production will override .env, but NOT .env.local or environment variables passed in
ENV_FILE=$CONTROLLER_DIR/.env
touch "$ENV_FILE"
echo PEWPEWCONTROLLER_UNITTESTS_S3_BUCKET_NAME="unit-test-bucket" >> "$ENV_FILE"
echo PEWPEWCONTROLLER_UNITTESTS_S3_BUCKET_URL="https://unit-test-bucket.s3.amazonaws.com" >> "$ENV_FILE"
echo PEWPEWCONTROLLER_UNITTESTS_S3_KEYSPACE_PREFIX="unittests/" >> "$ENV_FILE"
echo PEWPEWCONTROLLER_UNITTESTS_S3_REGION_ENDPOINT="s3-us-east-1.amazonaws.com" >> "$ENV_FILE"
echo APPLICATION_NAME=pewpewcontroller >> "$ENV_FILE"
echo AGENT_ENV="unittests" >> "$ENV_FILE"
echo AGENT_DESC="c5n.large" >> "$ENV_FILE"
echo PEWPEWAGENT_UNITTESTS_SQS_SCALE_OUT_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/unittests/sqs-scale-out" >> "$ENV_FILE"
echo PEWPEWAGENT_UNITTESTS_SQS_SCALE_IN_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/unittests/sqs-scale-in" >> "$ENV_FILE"
echo PEWPEWCONTROLLER_UNITTESTS_SQS_COMMUNICATION_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/unittests/sqs-communication" >> "$ENV_FILE"
- name: Install NPM Dependencies
run: npm ci
- name: Run Lint
run: npm run linterror
- name: Build Controller
env:
# Minimum variables needed to compile
PEWPEWCONTROLLER_UNITTESTS_S3_BUCKET_NAME: "unit-test-bucket"
PEWPEWCONTROLLER_UNITTESTS_S3_BUCKET_URL: "https://unit-test-bucket.s3.amazonaws.com"
PEWPEWCONTROLLER_UNITTESTS_S3_KEYSPACE_PREFIX: "unittests/"
PEWPEWCONTROLLER_UNITTESTS_S3_REGION_ENDPOINT: "s3-us-east-1.amazonaws.com"
APPLICATION_NAME: pewpewcontroller
AGENT_ENV: "unittests"
AGENT_DESC: "c5n.large"
PEWPEWAGENT_UNITTESTS_SQS_SCALE_OUT_QUEUE_URL: "https://sqs.us-east-1.amazonaws.com/unittests/sqs-scale-out"
PEWPEWAGENT_UNITTESTS_SQS_SCALE_IN_QUEUE_URL: "https://sqs.us-east-1.amazonaws.com/unittests/sqs-scale-in"
PEWPEWCONTROLLER_UNITTESTS_SQS_COMMUNICATION_QUEUE_URL: "https://sqs.us-east-1.amazonaws.com/unittests/sqs-communication"

run: npm run build:react
- name: Run Tests
run: NODE_ENV=test npm test

0 comments on commit 15675e2

Please sign in to comment.