diff --git a/monitoring/prometheus/gen-pass.py b/monitoring/prometheus/gen-pass.py new file mode 100644 index 0000000..6a1d04f --- /dev/null +++ b/monitoring/prometheus/gen-pass.py @@ -0,0 +1,9 @@ +# nix-shell -p python310Packages.bcrypt --run 'python gen-pass.py' +# https://prometheus.io/docs/guides/basic-auth/ + +import getpass +import bcrypt + +password = getpass.getpass("password: ") +hashed_password = bcrypt.hashpw(password.encode("utf-8"), bcrypt.gensalt()) +print(hashed_password.decode())