Skip to content

Commit

Permalink
fix salt renderer on olm manifest sls
Browse files Browse the repository at this point in the history
  • Loading branch information
eg-ayoub committed Jan 15, 2025
1 parent 3dd4f76 commit 9d7974f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
10 changes: 5 additions & 5 deletions olm/render.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@
START_BLOCK = """
#!jinja | metalk8s_kubernetes
{{%- from "metalk8s/map.jinja" import repo with context %}}
{{%- from "metalk8s/repo/macro.sls" import build_image_name with context %}}
{%- from "metalk8s/map.jinja" import repo with context %}
{%- from "metalk8s/repo/macro.sls" import build_image_name with context %}
{{% raw %}}
{% raw %}
"""

END_BLOCK = """
{{% endraw %}}
{% endraw %}
"""

class DownloadError(Exception):
Expand Down Expand Up @@ -121,7 +121,7 @@ def _fix_strings(obj):
else:
return obj
manifest = _fix_strings(manifest)
out = START_BLOCK
out = START_BLOCK.lstrip()
stream = io.StringIO()
yaml.safe_dump_all(
manifest,
Expand Down
9 changes: 4 additions & 5 deletions salt/metalk8s/addons/olm/deployed/chart.sls
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@

#!jinja | metalk8s_kubernetes

{{%- from "metalk8s/map.jinja" import repo with context %}}
{{%- from "metalk8s/repo/macro.sls" import build_image_name with context %}}
{%- from "metalk8s/map.jinja" import repo with context %}
{%- from "metalk8s/repo/macro.sls" import build_image_name with context %}

{{% raw %}}
{% raw %}
apiVersion: v1
kind: Namespace
metadata:
Expand Down Expand Up @@ -1704,4 +1703,4 @@ webhooks:
sideEffects: None
timeoutSeconds: 10

{{% endraw %}}
{% endraw %}

0 comments on commit 9d7974f

Please sign in to comment.