mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-04-19 22:52:02 +02:00
Removed list bug
This commit is contained in:
parent
cf44cb59b3
commit
b5dc999584
@ -23,7 +23,8 @@ defaults_domains:
|
||||
mailu: "mail.{{primary_domain}}"
|
||||
mastodon: "microblog.{{primary_domain}}"
|
||||
# ATTENTION: Will be owerwritten by the values in domains. Not merged.
|
||||
mastodon_alternates: ["mastodon.{{primary_domain}}"]
|
||||
mastodon_alternates:
|
||||
- "mastodon.{{primary_domain}}"
|
||||
matomo: "matomo.{{primary_domain}}"
|
||||
matrix_synapse: "matrix.{{primary_domain}}"
|
||||
matrix_element: "element.{{primary_domain}}"
|
||||
@ -47,7 +48,6 @@ defaults_domains:
|
||||
yourls: "s.{{primary_domain}}"
|
||||
# ATTENTION: Will be owerwritten by the values in domains. Not merged.
|
||||
wordpress:
|
||||
- "wordpress.{{primary_domain}}"
|
||||
- "blog.{{primary_domain}}"
|
||||
|
||||
## Domain Redirects
|
||||
@ -74,3 +74,4 @@ defaults_redirect_domain_mappings:
|
||||
- { source: "snipe-it.{{primary_domain}}", target: "{{domains.snipe_it}}" }
|
||||
- { source: "taiga.{{primary_domain}}", target: "{{domains.taiga}}" }
|
||||
- { source: "videos.{{primary_domain}}", target: "{{domains.peertube}}" }
|
||||
- { source: "wordpress.{{primary_domain}}", target: "{{domains.wordpress}}" }
|
||||
|
@ -85,10 +85,18 @@ class LookupModule(LookupBase):
|
||||
except Exception as e:
|
||||
raise AnsibleError("Error reading '{}': {}".format(meta_path, str(e)))
|
||||
|
||||
# Build URL and retrieve iframe flag
|
||||
# Retrieve domains and applications from the variables
|
||||
domains = variables.get("domains", {})
|
||||
applications = variables.get("applications", {})
|
||||
domain_url = domains.get(application_id, "")
|
||||
|
||||
# Check if domain_url is a list. If so, select the first element.
|
||||
if isinstance(domain_url, list):
|
||||
domain_url = domain_url[0]
|
||||
else:
|
||||
domain_url = ""
|
||||
|
||||
# Construct the URL using the domain_url if available.
|
||||
url = "https://" + domain_url if domain_url else ""
|
||||
|
||||
app_data = applications.get(application_id, {})
|
||||
|
Loading…
x
Reference in New Issue
Block a user