name: Test CI on: push: branches: [main] jobs: build: runs-on: rpi5 env: DOCKER_VOLUME: ${{ vars.DOCKER_VOLUME }} steps: - name: Checkout uses: actions/checkout@v4 - name: Check PWD run: | echo "Docker volume: $DOCKER_VOLUME" echo "PWD: $PWD" - name: Validate Node Environment run: | if ! command -v node &> /dev/null then echo "Error: Node.js not found" exit 1 fi echo "Node.js version: $(node -v)" - name: Restore node_modules id: cache-node uses: actions/cache@v4 with: path: node_modules key: ${{ runner.os }}-package-v1-${{ hashFiles('**/package-lock.json') }} restore-keys: | ${{ runner.os }}-package-v1- - name: Install Dependencies with Npm if: steps.cache-node.outputs.cache-hit != 'true' run: | npm install ls . - name: Build Nestjs project run: | npm run build ls . - name: Deploy dist run: | cp -r dist/* $DOCKER_VOLUME/scheduler/front/service/ ls $DOCKER_VOLUME/scheduler/front/service/