6 types: [opened, synchronize, reopened]
13 os: [windows-latest, macos-latest, ubuntu-latest]
14 node: ['16.x', '18.x', '20.x']
15 name: Build simulator with Node ${{ matrix.node }} on ${{ matrix.os }}
16 runs-on: ${{ matrix.os }}
18 - uses: actions/checkout@v4
20 fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
21 - name: 'Dependency Review'
22 if: ${{ matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
23 uses: actions/dependency-review-action@v3
26 head-ref: ${{ github.sha }}
27 - uses: pnpm/action-setup@v2
30 - name: Setup node ${{ matrix.node }}
31 uses: actions/setup-node@v3
33 node-version: ${{ matrix.node }}
36 run: pnpm install --ignore-scripts
38 if: ${{ matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
45 if: ${{ github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
47 - name: SonarCloud Scan
48 if: ${{ github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
49 uses: sonarsource/sonarcloud-github-action@v2.0.1
51 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
52 SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
56 os: [windows-latest, macos-latest, ubuntu-latest]
57 node: ['16.x', '18.x', '20.x']
58 name: Build dashboard with Node ${{ matrix.node }} on ${{ matrix.os }}
59 runs-on: ${{ matrix.os }}
62 working-directory: ui/web
64 - uses: actions/checkout@v4
66 fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
67 - name: 'Dependency Review'
68 if: ${{ matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
69 uses: actions/dependency-review-action@v3
72 head-ref: ${{ github.sha }}
73 - uses: pnpm/action-setup@v2
76 - name: Setup node ${{ matrix.node }}
77 uses: actions/setup-node@v3
79 node-version: ${{ matrix.node }}
82 run: pnpm install --ignore-scripts
84 if: ${{ matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
91 if: ${{ github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
93 - name: SonarCloud Scan
94 if: ${{ github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x' }}
95 uses: sonarsource/sonarcloud-github-action@v2.0.1
97 projectBaseDir: ui/web
99 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
100 SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
102 runs-on: ubuntu-latest
103 name: Build docker image
105 - uses: actions/checkout@v4
106 - name: Setup Docker Buildx
108 uses: docker/setup-buildx-action@v2
109 - name: Build docker image
112 make SUBMODULES_INIT=false