Validates domain names in rails