when I create s3 bucket with pulumi, pulumi adds a...
# general
b
when I create s3 bucket with pulumi, pulumi adds a random suffix to the specified bucket name, what could be the reason and how can I avoid that?
b
It’s for uniqueness. Bucket names have to be globally unique. I remember that you can turn that off. I’m looking how.
b
thanks
I know that they need to be unique, but in that specific case I prefer to take care of that
it is typically possible to provide a name: argument to the resource inputs
that's what I tried to do as soon as I saw the random name, but there is an error 'Argument of type '{ name: string; }' is not assignable to parameter of type 'BucketArgs'. Object literal may only specify known properties, and 'name' does not exist in type 'BucketArgs'.'
w
For
aws.s3.Bucket
in particular, you need to pass
bucket: "bucketname"
.
👍 1
b
I thought so, but then I've read the description of that parameter:
property bucket bucket?: pulumi.Input<string>; The ARN of the S3 bucket where you want Amazon S3 to store replicas of the object identified by the rule.
and that didn't make any sense to me
it works though, just tested
but I don't understand the property description
w
I believe the documentation there is unfortunately incorrect. This is https://github.com/pulumi/pulumi-terraform/issues/143.
👍 1
b
thank you, it's all clear now