# Discourse does not allow dot «.» symbol in bucket name while Amazon S3 allows it

**URL:** https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251
**Category:** Feature
**Created:** [2015年五月26日 09:16 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251 "2015-05-26T09:16:42Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![dmitry\_fedyuk](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dmitry_fedyuk/32/293153_2.png) [@dmitry\_fedyuk](https://meta.discourse.org/u/dmitry_fedyuk)
#### Post date: [2015年五月26日 09:16 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/1 "2015-05-26T09:16:42Z")

</div>

[Rules for Bucket Naming](http://docs.aws.amazon.com/AmazonS3/latest/dev/BucketRestrictions.html) from Amazon Documentation:

> Bucket names must be a series of one or more labels. Adjacent labels are separated by a single period (.).  
> \<…\>  
> The following examples are valid bucket names:  
> \<…\>  
> my.aws.bucket

Using a domain name as a bucket name is so naturally, especially for site backup, so it would be nice if Discourse will support it.

 ![](https://global.discourse-cdn.com/meta/original/3X/8/e/8e4ac738a74575c8159b23b58f845970efd96fed.png)

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [2015年五月26日 09:23 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/2 "2015-05-26T09:23:17Z")

</div>

We did that because we had issues with the gem we used to communicate with S3. Now that we’ve got rid of it, I think it’s safe to loosen the check a bit.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2015年五月26日 11:00 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/3 "2015-05-26T11:00:17Z")

</div>

Test it out, I think we may need to use a diff Api unless they fixed it in v2

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [2015年五月26日 14:13 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/4 "2015-05-26T14:13:29Z")

</div>

Just tested it and it worked fine 😉

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [2015年五月26日 14:13 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/5 "2015-05-26T14:13:31Z")

</div>



---

<div class="post-metadata">

### Author: ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)
#### Post date: [2015年五月27日 02:00 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/6 "2015-05-27T02:00:02Z")

</div>

Wait, isn’t the dot restriction because it causes HTTPS to fail?

yes, it is:

```
ssl.CertificateError: hostname 'my.bucket.s3.amazonaws.com' doesn't match either of '*.s3.amazonaws.com', 's3.amazonaws.com'

```

It’s the SSL certificate, not the gem.

edit: If discourse _isn’t_ always using SSL to talk to s3, that should be fixed. Both on server and client.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2015年五月27日 02:07 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/7 "2015-05-27T02:07:59Z")

</div>



---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [2015年五月27日 02:09 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/8 "2015-05-27T02:09:40Z")

</div>

Yes I agree, we should just disallow this, its adding complexity where complexity is not needed.

If people want vanity “sexy” names then can use s3\_cdn. A solution that only works with HTTP is not really acceptable.

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [2015年五月27日 09:12 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/9 "2015-05-27T09:12:49Z")

</div>

Thanks for figuring that one out ☀

[https://github.com/discourse/discourse/commit/5de955451027951600e5ad8b76fa7d38e086603d](https://github.com/discourse/discourse/commit/5de955451027951600e5ad8b76fa7d38e086603d)

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [2015年五月27日 20:35 UTC](https://meta.discourse.org/t/discourse-does-not-allow-dot-symbol-in-bucket-name-while-amazon-s3-allows-it/29251/10 "2015-05-27T20:35:59Z")

</div>


