An error occurred (NoSuchBucket) when calling the PutObject operation

I'm trying to upload the images of my django project to s3 bucket. I have the following in my settings

DEFAULT_FILE_STORAGE = 'storages.backends.s3boto3.S3Boto3Storage'

AWS_S3_ACCESS_KEY_ID = 'my_key_id'

AWS_S3_SECRET_ACCESS_KEY = 'my_secret_key'

AWS_STORAGE_BUCKET_NAME = 'app_name'

AWS_QUERYSTRING_AUTH = False

i have this in my aws permisions

{
"Version": "2012-10-17",
"Id": "Policy1665038511106",
"Statement": [
    {
        "Sid": "Stmt1665038504281",
        "Effect": "Allow",
        "Principal": "*",
        "Action": "s3:GetObject",
        "Resource": "arn:aws:s3:::novacreditbank/*"
    }
]

}

I keep getting this error

NoSuchBucket at /admin/Novaapp/data/1/change/

An error occurred (NoSuchBucket) when calling the PutObject operation: The specified bucket does not exist

Additionally, it appears your permission is for getObject, but will need another policy statement for PutObject.

Back to Top