Bump express from 4.18.2 to 4.19.2 in /frontend #184
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: Build | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: gradle/wrapper-validation-action@v1 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v3 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Cache Gradle packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.gradle/caches | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} | |
restore-keys: ${{ runner.os }}-gradle | |
- name: Cache SonarQube packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.sonar/cache | |
key: ${{ runner.os }}-sonar | |
restore-keys: ${{ runner.os }}-sonar | |
- name: Cache Node.js modules | |
uses: actions/cache@v3 | |
with: | |
path: ~/.npm | |
key: ${{ runner.OS }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.OS }}-node- | |
${{ runner.OS }}- | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'adopt' | |
java-version: 11 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '18.x' | |
- name: Build backend | |
run: | | |
cd backend | |
./gradlew build --info --warning-mode=summary | |
- name: Sonar analysis | |
if: ${{ env.SONAR_TOKEN != null }} | |
run: | | |
cd backend | |
./gradlew sonarqube -Dsonar.host.url=https://sonarcloud.io \ | |
-Dsonar.organization=kaklakariada-github \ | |
-Dsonar.login=$SONAR_TOKEN \ | |
--info --warning-mode=summary | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
- name: Configure infrastructure | |
run: | | |
cat > infrastructure/infrastructure-config.ts << EOF | |
import { InfrastructureConfig } from "./lib/infrastructure-config-interface"; | |
export const CONFIG: InfrastructureConfig = { | |
region: "eu-west-1", | |
domain: "ec2-controller.example.com", | |
hostedZoneName: "example.com.", | |
hostedZoneId: "XXXXXXXXXXXXXX", | |
sslCertificateArn: "arn:aws:acm:us-east-1:000000000000:certificate/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", | |
stackName: "ec2-controller", | |
contactEmailAddress: "admin@example.com" | |
}; | |
EOF | |
- name: Build infrastructure | |
run: | | |
cd infrastructure | |
npm ci | |
npm run cdk synth | |
npm run lint | |
- name: Configure frontend | |
run: | | |
cat > frontend/src/frontend-config.ts << EOF | |
import { FrontendConfig } from "./environment"; | |
export const CONFIG: FrontendConfig = { | |
region: "eu-west-1", | |
apiGatewayEndpointUrl: "https://xxxxxxxxxx.execute-api.eu-west-1.amazonaws.com/prod", | |
cognitoIdentityPoolId: "eu-west-1:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", | |
cognitoUserPoolId: "eu-west-1_xxxxxxxxx", | |
cognitoUserPoolWebClientId: "xxxxxxxxxxxxxxxxxxxxxxxxxx" | |
}; | |
EOF | |
- name: Build frontend | |
run: | | |
cd frontend | |
npm ci | |
npm run build | |
npm run lint |