Skip to content

Commit 502f489

Browse files
fix: resolve deploy failures for cq-demo-app-001 and cq-demo-app-004
- cq-demo-app-001: use npm install instead of npm ci (no lockfile) - cq-demo-app-004: add root health endpoint for health check - deploy-all.yml: increase health check timeout (sleep 60, retry 10) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 061cedd commit 502f489

3 files changed

Lines changed: 22 additions & 3 deletions

File tree

.github/workflows/deploy-all.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ jobs:
6666
- name: Health Check
6767
run: |
6868
APP_URL=$(az webapp show -g ${{ matrix.app.rg }} -n ${{ steps.infra.outputs.appServiceName }} --query defaultHostName -o tsv)
69-
sleep 30
70-
curl -sf --retry 5 --retry-delay 10 "https://$APP_URL" || exit 1
69+
sleep 60
70+
curl -sf --retry 10 --retry-delay 15 --retry-all-errors "https://$APP_URL" || exit 1
7171
7272
- name: Summary
7373
run: |

cq-demo-app-001/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
FROM node:20-alpine AS deps
22
WORKDIR /app
33
COPY package.json package-lock.json* ./
4-
RUN npm ci
4+
RUN npm install --production=false
55

66
FROM node:20-alpine AS builder
77
WORKDIR /app
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
package com.example.cqdemo.controller;
2+
3+
import org.springframework.web.bind.annotation.GetMapping;
4+
import org.springframework.web.bind.annotation.RestController;
5+
6+
import java.util.Map;
7+
8+
@RestController
9+
public class HealthController {
10+
11+
@GetMapping("/")
12+
public Map<String, String> root() {
13+
return Map.of(
14+
"status", "ok",
15+
"app", "cq-demo-app-004",
16+
"framework", "Spring Boot"
17+
);
18+
}
19+
}

0 commit comments

Comments
 (0)