MESOS_ATTRIBUTES="<% @attributes.sort.each do |key, val| -%><%= key -%>:<%= val -%>;<% end %>"
<% @mesos.sort.each do |key, val| -%>
<%= key.upcase -%>=<%= val %>
<% end -%>
<% unless @resources.empty? -%>
MESOS_RESOURCES="<%= scope.function_dcos_resources([@resources]).gsub('"', '\"') %>"
<% end -%>
<% if @region or @zone -%>
MESOS_DOMAIN="/var/lib/dcos/mesos-agent-domain.json"
<% end -%>
<% if @hostname -%>
MESOS_HOSTNAME="<%= @hostname %>"
<% end -%>
MESOS_ATTRIBUTES="<% @attributes.sort.each do |key, val| -%><%= key -%>:<%= val -%>;<% end %>"
<% @mesos.sort.each do |key, val| -%>
<%= key.upcase -%>=<%= val %>
<% end -%>
<% unless @resources.empty? -%>
MESOS_RESOURCES="<%= scope.function_dcos_resources([@resources]).gsub('"', '\"') %>"
<% end -%>
<% if @region or @zone -%>
MESOS_DOMAIN="/var/lib/dcos/mesos-agent-domain.json"
<% end -%>
Revert "Set hostname if defined"
Revert "Set hostname if defined"

This reverts commit 9c20b29cd30c38c70b40c0f6b5daf53f91e00544.
