mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-09-30 23:44:28 +02:00
[UI] use safe defaults for fetching cluster logs
This commit is contained in:
@@ -961,6 +961,8 @@ def get_operator_get_logs(worker: int):
|
||||
@app.route('/operator/clusters/<namespace>/<cluster>/logs')
|
||||
@authorize
|
||||
def get_operator_get_logs_per_cluster(namespace: str, cluster: str):
|
||||
team, cluster_name = cluster.split('-', 1)
|
||||
# team id might contain hivens, try to find correct team name
|
||||
user_teams = get_teams_for_user(session.get('user_name', ''))
|
||||
for user_team in user_teams:
|
||||
if cluster.find(user_team) == 0:
|
||||
|
||||
Reference in New Issue
Block a user