https://pulumi.com logo
#aws
Title
# aws
b

bitter-france-47214

08/25/2022, 5:34 PM
My
aws:cloudfront:Distribution
is failing because of following error:
Copy code
error creating CloudFront Distribution: InvalidArgument: The parameter Origin DomainName does not refer to a valid S3 bucket. status code: 400, request id: 59...eb1
I assume that this originates to following parts of the arguments:
Copy code
origins: [
        {
            originId: contentBucket.arn,
            domainName: contentBucket.websiteEndpoint,
            s3OriginConfig: {
                originAccessIdentity: originAccessIdentity.cloudfrontAccessIdentityPath,
            },
        },
    ],
Especially
contentBucket.websiteEndpoint
. I assume this is the problem. Pulumi outputs this as
<http://myDomain.app.s3-website.eu-central-1.amazonaws.com/>
which works fine so I don't quite know what the problem is. Can anybody help?
s

steep-toddler-94095

08/25/2022, 6:18 PM
perhaps you need to use the
bucketDomainName
instead?
👍 2
b

bitter-france-47214

08/25/2022, 10:31 PM
you're awesome mike! That worked. Thank you very much 🤩
p 1
2 Views