Solved oauth2 bugs and deactivated health-csp role temporary

This commit is contained in:
2025-05-13 14:34:16 +02:00
parent 687f9b0703
commit dc4964eda1
14 changed files with 38 additions and 82 deletions

View File

@@ -33,11 +33,32 @@ def get_csp_flags(applications, application_id: str, directive: str) -> list:
tokens.append("'unsafe-inline'")
return tokens
def get_docker_compose(path_docker_compose_instances: str, application_id: str) -> dict:
"""
Build the docker_compose dict based on
path_docker_compose_instances and application_id.
"""
base = f"{path_docker_compose_instances}{application_id}/"
return {
'directories': {
'instance': base,
'env': f"{base}.env/",
'services': f"{base}services/",
'volumes': f"{base}volumes/",
'config': f"{base}config/",
},
'files': {
'env': f"{base}.env/env",
'docker_compose': f"{base}docker-compose.yml",
}
}
class FilterModule(object):
def filters(self):
return {
'is_feature_enabled': is_feature_enabled,
'is_feature_enabled': is_feature_enabled,
'get_csp_whitelist': get_csp_whitelist,
'get_csp_flags': get_csp_flags,
'get_docker_compose': get_docker_compose,
}