Skip to content

Error when try to set Certificate to None in Distribution #2010

Discussion options

You must be logged in to vote

Using the below minimal .NET 6 code as provided by customer:

// See https://aka.ms/new-console-template for more information
using Amazon.CloudFront;
using Amazon.CloudFront.Model;

string cloudDistributionId = "<<specify your distribution id>>";
AmazonCloudFrontClient amazonCloudFrontClient = new AmazonCloudFrontClient();
var getDistributionRequest = new GetDistributionRequest() { Id = cloudDistributionId };
var dist = amazonCloudFrontClient.GetDistributionAsync(getDistributionRequest).Result;
var viewerCertificate = new ViewerCertificate()
{
    CloudFrontDefaultCertificate = false,
    MinimumProtocolVersion = MinimumProtocolVersion.TLSv1
};

dist.Distribution.DistributionConfig.Viewer…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by ashishdhingra
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
guidance Question that needs advice or information. response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. module/sdk-generated
2 participants
Converted from issue

This discussion was converted from issue #2009 on April 26, 2022 21:42.