[PR #14] 🔍 feat(casaos-healthcheck): Improve root and sudo privileges checks #18

Open
opened 2025-11-20 04:14:19 -05:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/bigbeartechworld/big-bear-scripts/pull/14

State: closed
Merged: Yes


Adds two new functions, check_root_privileges() and check_sudo_privileges(), to handle
the cases where the script is run with insufficient privileges. The script now
provides clearer instructions and prompts the user to either continue with the
limited functionality or exit and run the script with the required privileges.

Summary by CodeRabbit

  • New Features

    • Introduced enhanced privilege checks to ensure the script is run with appropriate permissions.
    • Added prompts for users regarding root and sudo access, improving user interaction and awareness.
  • Bug Fixes

    • Refined output messages for clarity during privilege checks.
  • Refactor

    • Improved code organization by replacing inline checks with dedicated functions for better readability and maintenance.
**Original Pull Request:** https://github.com/bigbeartechworld/big-bear-scripts/pull/14 **State:** closed **Merged:** Yes --- Adds two new functions, `check_root_privileges()` and `check_sudo_privileges()`, to handle the cases where the script is run with insufficient privileges. The script now provides clearer instructions and prompts the user to either continue with the limited functionality or exit and run the script with the required privileges. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced enhanced privilege checks to ensure the script is run with appropriate permissions. - Added prompts for users regarding root and sudo access, improving user interaction and awareness. - **Bug Fixes** - Refined output messages for clarity during privilege checks. - **Refactor** - Improved code organization by replacing inline checks with dedicated functions for better readability and maintenance. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
saavagebueno added the pull-request label 2025-11-20 04:14:19 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/big-bear-scripts#18