BucketRedirectRuleArgs

data class BucketRedirectRuleArgs(val hostName: Output<String>? = null, val httpRedirectCode: Output<String>? = null, val protocol: Output<BucketRedirectRuleProtocol>? = null, val replaceKeyPrefixWith: Output<String>? = null, val replaceKeyWith: Output<String>? = null) : ConvertibleToJava<BucketRedirectRuleArgs>

Specifies how requests are redirected. In the event of an error, you can specify a different error code to return.

Constructors

Link copied to clipboard
constructor(hostName: Output<String>? = null, httpRedirectCode: Output<String>? = null, protocol: Output<BucketRedirectRuleProtocol>? = null, replaceKeyPrefixWith: Output<String>? = null, replaceKeyWith: Output<String>? = null)

Properties

Link copied to clipboard
val hostName: Output<String>? = null

The host name to use in the redirect request.

Link copied to clipboard
val httpRedirectCode: Output<String>? = null

The HTTP redirect code to use on the response. Not required if one of the siblings is present.

Link copied to clipboard

Protocol to use when redirecting requests. The default is the protocol that is used in the original request.

Link copied to clipboard
val replaceKeyPrefixWith: Output<String>? = null

The object key prefix to use in the redirect request. For example, to redirect requests for all pages with prefix `docs/` (objects in the `docs/` folder) to `documents/`, you can set a condition block with `KeyPrefixEquals` set to `docs/` and in the Redirect set `ReplaceKeyPrefixWith` to `/documents`. Not required if one of the siblings is present. Can be present only if `ReplaceKeyWith` is not provided. Replacement must be made for object keys containing special characters (such as carriage returns) when using XML requests. For more information, see XML related object key constraints.

Link copied to clipboard
val replaceKeyWith: Output<String>? = null

The specific object key to use in the redirect request. For example, redirect request to `error.html`. Not required if one of the siblings is present. Can be present only if `ReplaceKeyPrefixWith` is not provided. Replacement must be made for object keys containing special characters (such as carriage returns) when using XML requests. For more information, see XML related object key constraints.

Functions

Link copied to clipboard
open override fun toJava(): BucketRedirectRuleArgs