gitea action test
This commit is contained in:
19
.github/workflows/deploy.yml
vendored
19
.github/workflows/deploy.yml
vendored
@@ -29,21 +29,12 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
|
|
||||||
# installer pnpm et wait-on globalement
|
- run: npm install -g pnpm wait-on
|
||||||
- run: |
|
|
||||||
npm install -g pnpm wait-on
|
|
||||||
|
|
||||||
# installer uniquement les deps prod
|
|
||||||
- run: pnpm install --frozen-lockfile --prod
|
- run: pnpm install --frozen-lockfile --prod
|
||||||
|
- run: pnpm start > server.log 2>&1 &
|
||||||
# démarrer le serveur en arrière-plan
|
- run: tail -n 20 server.log
|
||||||
- run: pnpm start &
|
- run: wait-on http://localhost:3000 --timeout 60000
|
||||||
|
- run: curl -f http://localhost:3000 || (cat server.log && exit 1)
|
||||||
# attendre que le serveur soit dispo (max 15s)
|
|
||||||
- run: wait-on http://localhost:3000 --timeout 15000
|
|
||||||
|
|
||||||
# vérifier la route principale
|
|
||||||
- run: curl -f http://localhost:3000 || exit 1
|
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
|
|||||||
Reference in New Issue
Block a user