Debug tips

This commit is contained in:
Jokob-sk
2023-07-18 08:06:32 +10:00
parent 536d789535
commit 98fb02282b
2 changed files with 22 additions and 14 deletions

View File

@@ -1,23 +1,17 @@
## More Logging
# Debugging and troubleshooting
Please follow tips 1 - 4 to get a more detailed error.
## 1. More Logging 📃
When debugging an issue always set the highest log level:
`LOG_LEVEL='debug'`
## Check the _dev image and open issues
## 2. Surfacing errors when container restarts 🔁
If possible, check if your issue got fixed in the `_dev` image before opening a new issue. The container is:
`jokobsk/pi.alert_dev:latest`
> ⚠ Please backup your DB and config beforehand!
Please also search [open issues](https://github.com/jokob-sk/Pi.Alert/issues).
## Surfacing errors when container restarts
Start the container via the terminal with a command similar to this one:
Start the container via the **terminal** with a command similar to this one:
```bash
docker run --rm --network=host \
@@ -31,7 +25,17 @@ docker run --rm --network=host \
> ⚠ Please note, don't use the `-d` parameter so you see the error when the container crashes. Use this error in your issue description.
## Disable restart behavior
## 3. Check the _dev image and open issues ❓
If possible, check if your issue got fixed in the `_dev` image before opening a new issue. The container is:
`jokobsk/pi.alert_dev:latest`
> ⚠ Please backup your DB and config beforehand!
Please also search [open issues](https://github.com/jokob-sk/Pi.Alert/issues).
## 4. Disable restart behavior 🛑
To prevent a Docker container from automatically restarting in a Docker Compose file, specify the restart policy as `no`: