str
An optional description of this resource.
Provide this property when you create the
resource.
This field is a member of oneof_ _description.
hosts
MutableSequence[str]
The list of host patterns to match. They must be valid
hostnames with optional port numbers in the format
host:port. \* matches any string of ([a-z0-9-.]*). In that
case, \* must be the first character, and if followed by
anything, the immediate following character must be either -
or .. \* based matching is not supported when the URL map is
bound to a target gRPC proxy that has the
validateForProxyless field set to true.
path_matcher
str
The name of the PathMatcher to use to match
the path portion of the URL if the hostRule
matches the URL's host portion.
This field is a member of oneof_ _path_matcher.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Class HostRule (0.1.5)\n\nVersion latestkeyboard_arrow_down\n\n- [0.1.5 (latest)](/python/docs/reference/google-cloud-compute-v1beta/latest/google.cloud.compute_v1beta.types.HostRule)\n- [0.1.4](/python/docs/reference/google-cloud-compute-v1beta/0.1.4/google.cloud.compute_v1beta.types.HostRule) \n\n HostRule(mapping=None, *, ignore_unknown_fields=False, **kwargs)\n\nUrlMaps A host-matching rule for a URL. If matched, will use\nthe named PathMatcher to select the BackendService.\n\n.. _oneof: \u003chttps://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields\u003e"]]