summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-06-10 07:46:05 +0200
committerGitHub <noreply@github.com>2023-06-10 07:46:05 +0200
commit6c8c4e212b40af8097d810a00bc5664190dbd7f2 (patch)
treefe3d7128948749a1844c61b5a02e371f490c4c82
parent0b99a4cba1279b5a27d2fa013004501f89b3edce (diff)
parentfbcb22c1850c8371dffc2cf9dbda0fe83031df10 (diff)
downloadvyos-1x-6c8c4e212b40af8097d810a00bc5664190dbd7f2.tar.gz
vyos-1x-6c8c4e212b40af8097d810a00bc5664190dbd7f2.zip
Merge pull request #2034 from erkin/current
T3472: Print warning when commit-confirm is run as regular user
-rwxr-xr-xsrc/helpers/commit-confirm-notify.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/helpers/commit-confirm-notify.py b/src/helpers/commit-confirm-notify.py
index eb7859ffa..8d7626c78 100755
--- a/src/helpers/commit-confirm-notify.py
+++ b/src/helpers/commit-confirm-notify.py
@@ -17,6 +17,7 @@ def notify(interval):
if __name__ == "__main__":
# Must be run as root to call wall(1) without a banner.
if len(sys.argv) != 2 or os.getuid() != 0:
+ print('This script requires superuser privileges.', file=sys.stderr)
exit(1)
minutes = int(sys.argv[1])
# Drop the argument from the list so that the notification