mirror of
https://github.com/enpaul/vault2vault.git
synced 2024-11-22 18:16:47 +00:00
parent
67af43ce43
commit
5c97b869a8
@ -370,7 +370,7 @@ def _load_password(
|
|||||||
if fpath:
|
if fpath:
|
||||||
try:
|
try:
|
||||||
with Path(fpath).resolve().open("rb") as infile:
|
with Path(fpath).resolve().open("rb") as infile:
|
||||||
return VaultSecret(infile.read())
|
return VaultSecret(infile.read().strip())
|
||||||
except (FileNotFoundError, PermissionError) as err:
|
except (FileNotFoundError, PermissionError) as err:
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
f"Specified vault password file '{fpath}' does not exist or is unreadable"
|
f"Specified vault password file '{fpath}' does not exist or is unreadable"
|
||||||
|
Loading…
Reference in New Issue
Block a user