{#- 
  This template is rendered by the render_meta.py script
  it is not automatically enforced by OBS
-#}
{%- set maintainers = [
    "edge-engineering",
] -%}
<project name="{{ project }}">
  <title>{{ title }}</title>
  {%- if description is defined %}
  <description>{{ description }}</description>
  {%- else %}
  <description/>
  {%- endif %}
  {%- if scm_url is defined %}
  <scmsync>{{ scm_url }}</scmsync>
  {%- endif %}
{%- for maintainer in maintainers %}
  <person userid="{{ maintainer }}" role="maintainer"/>
{%- endfor %}
{%- if not base_project %}
  <build>
    <disable/>
    <enable repository="charts"/>
    <enable repository="test_manifest_images"/>
    {%- if for_release %}
    <enable repository="releasecharts"/>
    {%- endif %}
  </build>
  <publish>
    <disable repository="phantomcharts"/>
  </publish>
  <repository name="phantomcharts">
    <arch>x86_64</arch>
  </repository>
{%- endif %}
{%- for repository in ["images", "test_manifest_images"] %}
  <repository name="{{ repository }}">
    {%- if release_project is defined and repository != "test_manifest_images" %}
    <releasetarget project="{{ release_project }}" repository="images" trigger="manual"/>
    {%- endif %}
    <path project="SUSE:Registry" repository="standard"/>
    <path project="{{ ironic_base }}:Factory" repository="16.0"/>
    <path project="SUSE:CA" repository="openSUSE_Tumbleweed"/>
    <path project="{{ project }}" repository="standard"/>
    <arch>x86_64</arch>
    <arch>aarch64</arch>
  </repository>
{%- endfor %}
  <repository name="standard" block="local">
    {%- if release_project is defined and not for_release %}
    <releasetarget project="{{ release_project }}" repository="standard" trigger="manual"/>
    {%- endif %}
    <path project="{{ ironic_base }}:Factory" repository="16.0"/>
    <path project="SUSE:SLFO:Products:SLES:16.0" repository="standard"/>
    <path project="SUSE:SLFO:1.2" repository="standard"/>
    <arch>x86_64</arch>
    <arch>aarch64</arch>
  </repository>
  <repository name="charts"{{ ' rebuild="local"' if not base_project }}>
    {%- if release_project is defined and not for_release %}
    <releasetarget project="{{ release_project }}" repository="phantomcharts" trigger="manual"/>
    {%- endif %}
    <path project="{{ project }}" repository="standard"/>
    <arch>x86_64</arch>
  </repository>
  {%- if for_release %}
  <repository name="releasecharts" rebuild="local">
    <releasetarget project="{{ release_project }}" repository="charts" trigger="manual"/>
    <path project="{{ project }}" repository="standard"/>
    <arch>x86_64</arch>
  </repository>
  {%- endif %}
</project>
