# Backup to DigitalOcean Spaces fails if uploads and backup are both set to S3

**URL:** <https://meta.discourse.org/t/backup-to-digitalocean-spaces-fails-if-uploads-and-backup-are-both-set-to-s3/106916>\
**Category:** Support\
**Created:** [January 18, 2019, 3:21pm UTC](https://meta.discourse.org/t/backup-to-digitalocean-spaces-fails-if-uploads-and-backup-are-both-set-to-s3/106916 "2019-01-18T15:21:11Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)\
**Post date:** [January 28, 2019, 3:41pm UTC](https://meta.discourse.org/t/backup-to-digitalocean-spaces-fails-if-uploads-and-backup-are-both-set-to-s3/106916/7 "2019-01-28T15:41:37Z")

</div>

> [@pfaffman](#):
>
> not being able to share buckets

Yeah, that’s just a simple explanation and a recommendation. However, there are multiple configuration options:

> [@S3 image upload access denied while backups upload working fine](https://meta.discourse.org/t/s3-image-upload-access-denied-while-backups-upload-working-fine/104071/16):
>
> Essentially you need to either use two different buckets or a prefix for the backup bucket. For example, the following combinations will work:
> 
> 1. Different buckets
> 
> - `s3_upload_bucket` : `my-upload-bucket`
> - `s3_backup_bucket` : `my-backup-bucket`
> 
> 1. Different prefixes
> 
> - `s3_upload_bucket` : `my-bucket/uploads`
> - `s3_backup_bucket` : `my-bucket/backups`
> 
> 1. Prefix for backups
> 
> - `s3_upload_bucket` : `my-bucket`
> - `s3_backup_bucket` : `my-bucket/backups`

Multisites always store the backups in `<s3_backup_bucket>/backups/<site_name>`.

> <https://github.com/discourse/discourse/blob/main/lib/backup_restore/s3_backup_store.rb#L102-L103>

---

_[View the full topic](https://meta.discourse.org/t/backup-to-digitalocean-spaces-fails-if-uploads-and-backup-are-both-set-to-s3/106916)._
