fix issues with template sorting and frequent, unnecessary haproxy reconfiguring

Signed-off-by: Joshua Rubin <jrubin@zvelo.com>