summaryrefslogtreecommitdiffstats
path: root/munin/publik_count_
diff options
context:
space:
mode:
Diffstat (limited to 'munin/publik_count_')
-rwxr-xr-xmunin/publik_count_7
1 files changed, 6 insertions, 1 deletions
diff --git a/munin/publik_count_ b/munin/publik_count_
index 173c38c..14aa8d6 100755
--- a/munin/publik_count_
+++ b/munin/publik_count_
@@ -35,7 +35,12 @@ total_logged_user_count.label Front by logged user
for tenant_dir in itertools.chain(os.listdir(base_dir), os.listdir(os.path.join(base_dir, 'tenants'))):
if tenant_dir != tenant:
continue
- cfg = pickle.load(open(os.path.join(base_dir, tenant, 'config.pck'), 'rb'), encoding='utf-8')
+ dirname = os.path.join(base_dir, tenant)
+ if not os.path.exists(dirname):
+ dirname = os.path.join(base_dir, 'tenants', tenant)
+ if not os.path.isdir(dirname):
+ continue
+ cfg = pickle.load(open(os.path.join(dirname, 'config.pck'), 'rb'), encoding='utf-8')
if 'postgresql' not in cfg:
continue
psql_cfg = {}