From 326b88195d8ddaf968442034aa84005b05fdf4b0 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Tue, 23 Apr 2024 11:44:42 +0300 Subject: Make the keys storage dir depend on the more generic uploads directory --- gn_auth/__init__.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'gn_auth') diff --git a/gn_auth/__init__.py b/gn_auth/__init__.py index f7e2620..224b681 100644 --- a/gn_auth/__init__.py +++ b/gn_auth/__init__.py @@ -65,7 +65,9 @@ def parse_ssl_public_keys(app): with open(keypath) as _sslkey: return JsonWebKey.import_key(_sslkey.read()) - key_storage_dir = app.config["CLIENTS_SSL_PUBLIC_KEYS_DIR"] + key_storage_dir = Path(app.config["UPLOADS_DIR"]).joinpath( + "clients-ssl-keys") + app.config["CLIENTS_SSL_PUBLIC_KEYS_DIR"] = key_storage_dir app.config["SSL_PUBLIC_KEYS"] = { _key.as_dict()["kid"]: _key for _key in ( __parse_key__(Path(key_storage_dir).joinpath(key)) -- cgit v1.2.3