Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add maintenance mode #243

Open
psikoi opened this issue Feb 28, 2024 · 0 comments
Open

Add maintenance mode #243

psikoi opened this issue Feb 28, 2024 · 0 comments

Comments

@psikoi
Copy link
Member

psikoi commented Feb 28, 2024

We need a way to shut the bot down when our API is down, this can be done in two ways:

Hands off approach

  • Ping https://api.wiseoldman.net/v2/ every minute or so, check if it doesn't return a 200 status code
    • If it gets more than X negative pings in a row, turn on "maintenance mode" and respond with a generic message
  • No manual input from me needed, i could be asleep!

Hands on

  • Read a MAINTENANCE_MODE_ENABLED env var, and respond with a generic message
  • Requires me to log on to the server, update the env vars, restart the bot container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant