-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
issue #48 - examples on monitoring the application
- Loading branch information
1 parent
810bcbb
commit 2322ce3
Showing
2 changed files
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Monitoring OS2BorgerPC admin-site | ||
|
||
There are various ways of monitoring the application, som are: | ||
1) health check | ||
2) viewing logs | ||
3) viewing resource usage | ||
|
||
Below are examples on how this can be done for the provided docker-compose testing setup that can be used as inspiration. | ||
|
||
## Health check | ||
This section in the compose.yaml shows how to implement a health check for a docker-compose setup. | ||
``` | ||
restart: always | ||
healthcheck: | ||
test: ["CMD", "curl", "-f", "http://localhost:9999"] | ||
interval: 30s | ||
timeout: 10s | ||
retries: 3 | ||
start_period: 5s | ||
``` | ||
|
||
## Viewing logs | ||
``` | ||
docker logs bpc_admin_site_django | ||
``` | ||
|
||
## Viewing resource usage | ||
``` | ||
docker stats bpc_admin_site_django | ||
``` |