Skip to content

OriginRuleProps

Properties for defining a OriginRule.

See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-esa-originrule

Initializer

import ros_cdk_esa
ros_cdk_esa.OriginRuleProps(
  site_id: typing.Union[typing.Union[int, float], IResolvable],
  dns_record: typing.Union[str, IResolvable] = None,
  follow302_enable: typing.Union[str, IResolvable] = None,
  follow302_max_tries: typing.Union[typing.Union[int, float], IResolvable] = None,
  follow302_retain_args: typing.Union[str, IResolvable] = None,
  follow302_retain_header: typing.Union[str, IResolvable] = None,
  follow302_target_host: typing.Union[str, IResolvable] = None,
  origin_host: typing.Union[str, IResolvable] = None,
  origin_http_port: typing.Union[typing.Union[int, float], IResolvable] = None,
  origin_https_port: typing.Union[typing.Union[int, float], IResolvable] = None,
  origin_mtls: typing.Union[str, IResolvable] = None,
  origin_read_timeout: typing.Union[typing.Union[int, float], IResolvable] = None,
  origin_scheme: typing.Union[str, IResolvable] = None,
  origin_sni: typing.Union[str, IResolvable] = None,
  origin_verify: typing.Union[str, IResolvable] = None,
  range: typing.Union[str, IResolvable] = None,
  range_chunk_size: typing.Union[str, IResolvable] = None,
  rule: typing.Union[str, IResolvable] = None,
  rule_enable: typing.Union[str, IResolvable] = None,
  rule_name: typing.Union[str, IResolvable] = None,
  sequence: typing.Union[typing.Union[int, float], IResolvable] = None,
  site_version: typing.Union[typing.Union[int, float], IResolvable] = None
)

Properties

Name Type Description
site_id typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property siteId: The site ID.
dns_record typing.Union[str, ros_cdk_core.IResolvable] Property dnsRecord: Overwrite the DNS resolution record of the origin request.
follow302_enable typing.Union[str, ros_cdk_core.IResolvable] Property follow302Enable: Return Source 302 follow switch.
follow302_max_tries typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property follow302MaxTries: 302 follows the upper limit of the number of times, with a value range of [1-5].
follow302_retain_args typing.Union[str, ros_cdk_core.IResolvable] Property follow302RetainArgs: Retain the original request parameter switch.
follow302_retain_header typing.Union[str, ros_cdk_core.IResolvable] Property follow302RetainHeader: Retain the original request header switch.
follow302_target_host typing.Union[str, ros_cdk_core.IResolvable] Property follow302TargetHost: Modify the source host after 302.
origin_host typing.Union[str, ros_cdk_core.IResolvable] Property originHost: The HOST carried in the back-to-origin request.
origin_http_port typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property originHttpPort: The port of the origin station accessed when the HTTP protocol is used to return to the origin.
origin_https_port typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property originHttpsPort: Port of the origin server when using the HTTPS protocol for origin requests.
origin_mtls typing.Union[str, ros_cdk_core.IResolvable] Property originMtls: The mtls switch.
origin_read_timeout typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property originReadTimeout: Read timeout interval of the source station (s).
origin_scheme typing.Union[str, ros_cdk_core.IResolvable] Property originScheme: The protocol used by the back-to-origin request.
origin_sni typing.Union[str, ros_cdk_core.IResolvable] Property originSni: SNI carried in the back-to-origin request.
origin_verify typing.Union[str, ros_cdk_core.IResolvable] Property originVerify: Source station certificate verification switch.
range typing.Union[str, ros_cdk_core.IResolvable] Property range: Use the range sharding method to download the file from the source.
range_chunk_size typing.Union[str, ros_cdk_core.IResolvable] Property rangeChunkSize: range shard size.
rule typing.Union[str, ros_cdk_core.IResolvable] Property rule: Rule content, using conditional expressions to match user requests.
rule_enable typing.Union[str, ros_cdk_core.IResolvable] Property ruleEnable: Rule switch.
rule_name typing.Union[str, ros_cdk_core.IResolvable] Property ruleName: Rule name.
sequence typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property sequence: Order of rule execution.
site_version typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] Property siteVersion: The version number of the site configuration.

site_idRequired

site_id: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property siteId: The site ID.


dns_recordOptional

dns_record: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property dnsRecord: Overwrite the DNS resolution record of the origin request.


follow302_enableOptional

follow302_enable: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property follow302Enable: Return Source 302 follow switch.

Value range:

  • on: ON.
  • off: closed.

follow302_max_triesOptional

follow302_max_tries: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property follow302MaxTries: 302 follows the upper limit of the number of times, with a value range of [1-5].


follow302_retain_argsOptional

follow302_retain_args: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property follow302RetainArgs: Retain the original request parameter switch.

Value range:

  • on: ON.
  • off: closed.

follow302_retain_headerOptional

follow302_retain_header: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property follow302RetainHeader: Retain the original request header switch.

Value range:

  • on: ON.
  • off: closed.

follow302_target_hostOptional

follow302_target_host: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property follow302TargetHost: Modify the source host after 302.


origin_hostOptional

origin_host: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property originHost: The HOST carried in the back-to-origin request.


origin_http_portOptional

origin_http_port: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property originHttpPort: The port of the origin station accessed when the HTTP protocol is used to return to the origin.


origin_https_portOptional

origin_https_port: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property originHttpsPort: Port of the origin server when using the HTTPS protocol for origin requests.


origin_mtlsOptional

origin_mtls: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property originMtls: The mtls switch.

Value range:

  • on: ON.
  • off: closed.

origin_read_timeoutOptional

origin_read_timeout: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property originReadTimeout: Read timeout interval of the source station (s).


origin_schemeOptional

origin_scheme: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property originScheme: The protocol used by the back-to-origin request.

Value range:

  • http: uses the http protocol to return to the source.
  • https: uses the https protocol to return to the source.
  • follow: follows the Client Protocol back to the source.

origin_sniOptional

origin_sni: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property originSni: SNI carried in the back-to-origin request.


origin_verifyOptional

origin_verify: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property originVerify: Source station certificate verification switch.

Value range:

  • on: ON.
  • off: closed.

rangeOptional

range: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property range: Use the range sharding method to download the file from the source.

Value range:

  • on: Open.
  • off: off.
  • force: force.

range_chunk_sizeOptional

range_chunk_size: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property rangeChunkSize: range shard size.


ruleOptional

rule: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property rule: Rule content, using conditional expressions to match user requests.

When adding global configuration, this parameter does not need to be set. There are two usage scenarios:

  • Match all incoming requests: value set to true
  • Match specified request: Set the value to a custom expression, for example: (http.host eq "video.example.com").

rule_enableOptional

rule_enable: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property ruleEnable: Rule switch.

When adding global configuration, this parameter does not need to be set. Value range:

  • on: open.
  • off: close.

rule_nameOptional

rule_name: typing.Union[str, IResolvable]
  • Type: typing.Union[str, ros_cdk_core.IResolvable]

Property ruleName: Rule name.

When adding global configuration, this parameter does not need to be set.


sequenceOptional

sequence: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property sequence: Order of rule execution.

The smaller the value, the higher the priority for execution.


site_versionOptional

site_version: typing.Union[typing.Union[int, float], IResolvable]
  • Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]

Property siteVersion: The version number of the site configuration.

For sites that have enabled configuration version management, this parameter can be used to specify the effective version of the configuration site, which defaults to version 0.