{% set obsolete_message = "This software type doesn't exist anymore. Please ask Rapid.Space team to switch your services to the correct software types (gNB, eNB and Core Network)" -%}

{% set part_list = [] -%}
{%- for i, slave in enumerate(slave_instance_list) %}
{%    set slave_reference = slave.get('slave_reference', '') %}
{%    set publish_section_title = 'publish-%s' % slave_reference %}
{%    do part_list.append(publish_section_title) %}
[{{ publish_section_title }}]
recipe = slapos.cookbook:publish.serialised
-slave-reference = {{ slave_reference }}
info = {{ obsolete_message }}
{%- endfor %}

[buildout]
parts =
  publish-connection-information
{% for part in part_list -%}
{{ '  %s' % part }}
{% endfor %}

eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true

[publish-connection-information]
recipe = slapos.cookbook:publish.serialised
message = {{ obsolete_message }}
