CmdID

CmdID / aws / aws cloudfront

aws cloudfront update-distribution-tenant

Updates a distribution tenant. AWS CLI reference

1 example 9 options Its page in the AWS CLI reference

Opens CmdID with your command. It is read in your browser and sent nowhere.

Examples

from aws-cli, each command read by CmdID

To update a CloudFront distribution tenant

The following update-distribution-tenant example updates a CloudFront distribution tenant with a new parameter value and adds a country to the geo-restrictions.

aws cloudfront update-distribution-tenant --cli-input-json file://update-tenant.jsonIdentify

Contents of update-tenant.json:

{
    "Id": "dt_2yMvQgam3QkJo2z54FDl91dk1AB",
    "IfMatch": "E1F83G8C2ARABC",
    "Parameters": [
        {
            "Name": "testParam",
            "Value": "newParameterValue"
        }
    ],
    "Customizations": {
        "WebAcl": {
            "Action": "disable"
        },
        "GeoRestrictions": {
            "RestrictionType": "whitelist",
            "Locations": [
                "DE",
                "GB",
                "ES"
            ]
        }
    }
}
Its output, shortened
{
    "ETag": "E1PA6795UKMABC",
    "DistributionTenant": {
        "Id": "dt_2yMvQgam3QkJo2z54FDl91dk1AB",
        "DistributionId": "E1XNX8R2GOAABC",
        "Name": "new-tenant-customizations",
        "Arn": "arn:aws:cloudfront::123456789012:distribution-tenant/dt_2yMvQgam3QkJo2z54FDl91dk1AB",
        "Domains": [
            {
                "Domain": "example.com",
                "Status": "active"
            }
        ],
        "Customizations": {
            "WebAcl": {
                "Action": "disable"
            },
            "GeoRestrictions": {
                "RestrictionType": "whitelist",
                "Locations": [
                    "DE",
                    "ES",
                    "GB"
                ]
            }
        },
        "Parameters": [
            {
                "Name": "testParam",
                "Value": "newParameterValue"
… 9 more lines

For more information, see Distribution tenant customizations in the Amazon CloudFront Developer Guide.

Options

9 in the AWS CLI reference
--connection-group-idThe ID of the target connection group.
--customizationsCustomizations for the distribution tenant.
--distribution-idThe ID for the multi-tenant distribution.
--domainsThe domains to update for the distribution tenant.
--enabledIndicates whether the distribution tenant should be updated to an enabled state.
--idThe ID of the distribution tenant.
--if-matchThe value of the ETag header that you received when retrieving the distribution tenant to update.
--managed-certificate-requestAn object that contains the CloudFront managed ACM certificate request.
--parametersA list of parameter values to add to the resource.