diff --git a/.github/build-backend.yaml b/.github/build-backend.yaml new file mode 100644 index 0000000..4d22740 --- /dev/null +++ b/.github/build-backend.yaml @@ -0,0 +1,36 @@ +name: Test build backend + +on: + pull_request: + paths: + - "backend/**" + + push: + branches: + - master + paths: + - "backend/**" + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + + - name: Install dependencies + working-directory: backend + run: npm install + + - run: npm run build + working-directory: backend diff --git a/.github/build-frontend.yaml b/.github/build-frontend.yaml new file mode 100644 index 0000000..1e35a2e --- /dev/null +++ b/.github/build-frontend.yaml @@ -0,0 +1,36 @@ +name: Test build frontend + +on: + pull_request: + paths: + - "frontend/**" + + push: + branches: + - master + paths: + - "frontend/**" + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + + - name: Install dependencies + working-directory: frontend + run: npm install + + - run: CI=false npm run build + working-directory: frontend diff --git a/.github/workflows/build-backend.yaml b/.github/workflows/push-image-backend.yaml similarity index 100% rename from .github/workflows/build-backend.yaml rename to .github/workflows/push-image-backend.yaml diff --git a/.github/workflows/build-frontend.yaml b/.github/workflows/push-image-frontend.yaml similarity index 100% rename from .github/workflows/build-frontend.yaml rename to .github/workflows/push-image-frontend.yaml