Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ jobs:
working-directory: frontend
- run: docker compose build
- run: docker compose down -v --remove-orphans
- run: docker compose up -d
- run: docker compose up -d --wait
- name: Run Playwright tests
run: npx playwright test
run: npx playwright test --fail-on-flaky-tests --trace=retain-on-failure
working-directory: frontend
- run: docker compose down -v --remove-orphans
- uses: actions/upload-artifact@v4
Expand Down
5 changes: 5 additions & 0 deletions backend/app/api/routes/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,8 @@ def test_email(email_to: EmailStr) -> Message:
html_content=email_data.html_content,
)
return Message(message="Test email sent")


@router.get("/health-check/")
async def health_check() -> bool:
return True
6 changes: 6 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ services:
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD?Variable not set}
- SENTRY_DSN=${SENTRY_DSN}

healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/api/v1/utils/health-check/"]
interval: 10s
timeout: 5s
retries: 5

build:
context: ./backend
args:
Expand Down
12 changes: 12 additions & 0 deletions frontend/src/client/services.ts
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,18 @@ export class UtilsService {
},
})
}

/**
* Health Check
* @returns boolean Successful Response
* @throws ApiError
*/
public static healthCheck(): CancelablePromise<boolean> {
return __request(OpenAPI, {
method: "GET",
url: "/api/v1/utils/health-check/",
})
}
}

export type TDataReadItems = {
Expand Down