{% if pillar['ssh']['user-pub-keys'] %} {{ pillar['username'] }}_autherized_keys: ssh_auth: - present - user: {{ pillar['username'] }} - names: {{ pillar['ssh']['user-pub-keys'] }} {% endif %}