Nginx: Update the logic for config templates customization.