blob: 089f15e2220b9962c8fdb04ebeef1859db6fe416 [file] [log] [blame]
{%- from "tftpd_hpa/map.jinja" import server with context %}
{%- set opts = [] %}
{%- for data in server.get('options', []) %}
{%- if data is mapping %}
{%- for opt, val in data.iteritems() %}
{%- do opts.append('--' + opt + ' ' + val) %}
{%- endfor %}
{%- else %}
{%- do opts.append("--" + data) %}
{%- endif %}
{%- endfor -%}
TFTP_USERNAME="{{ server.username }}"
TFTP_DIRECTORY="{{ server.path }}"
TFTP_ADDRESS="{{ server.bind.address }}:{{ server.bind.port }}"
TFTP_OPTIONS="{{ ' '.join(opts) }}"