def scan_unit_configs(stacks_by_name)
        all = {}
        stacks_by_name.each do |_, stack|
          stack.fetch(:units, []).each do |unit_config|
            next if unit_config.fetch(:instances, 1) == 1
            all[unit_config.name] = 1.upto(unit_config.instances).map do |number|
              "#{unit_config.name}#{number}"
            end
          end
        end
        all
      end
def scan_unit_configs(stacks_by_name)
        all = {}
        stacks_by_name.each do |_, stack|
          stack.fetch(:units, []).each do |unit_config|
            next if unit_config.fetch(:instances, 1) == 1
            all[unit_config.name] = 1.upto(unit_config.instances).map do |number|
              "#{unit_config.name}#{number}"
            end
          end
        end
        all
      end
FIXME