#!/bin/sh

<% @certificates.each_value do |certificate| -%>
<% certificate[:nodes].each do |host| -%>
/srv/acme.openstreetmap.org/bin/check-certificate <%= host[:name] %> <%= host[:address] %> <%= certificate[:domains].join(" ") %>
<% end -%>
<% end -%>

#!/bin/sh

<% @certificates.values.sort_by { |c| c[:domains].first }.each do |certificate| -%>
<% certificate[:nodes].sort_by { |h| h[:name] }.each do |host| -%>
/srv/acme.openstreetmap.org/bin/check-certificate <%= host[:name] %> <%= host[:address] %> <%= certificate[:domains].join(" ") %>
<% end -%>
<% end -%>

Sort certificates in a stable order
Sort certificates in a stable order
