We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1fbdd1c commit f919b3bCopy full SHA for f919b3b
1 file changed
src/murfey/server/murfey_db.py
@@ -15,10 +15,10 @@ def url(security_config: Security | None = None) -> str:
15
security_config = security_config or get_security_config()
16
with open(security_config.murfey_db_credentials, "r") as stream:
17
creds = yaml.safe_load(stream)
18
- f = Fernet(security_config.crypto_key.encode("ascii"))
19
- p = f.decrypt(creds["password"].encode("ascii"))
20
if security_config.db == "sqlite":
21
return f"sqlite:///{creds['database']}"
+ f = Fernet(security_config.crypto_key.encode("ascii"))
+ p = f.decrypt(creds["password"].encode("ascii"))
22
return f"postgresql+psycopg2://{creds['username']}:{p.decode()}@{creds['host']}:{creds['port']}/{creds['database']}"
23
24
0 commit comments