# Issue pulling model from S3

**URL:** <https://forum.rasa.com/t/issue-pulling-model-from-s3/41894>\
**Category:** Rasa Open Source\
**Created:** [March 30, 2021, 5:07pm UTC](https://forum.rasa.com/t/issue-pulling-model-from-s3/41894 "2021-03-30T17:07:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![obi-wan](https://avatars.discourse-cdn.com/v4/letter/o/f4b2a3/32.png) [@obi-wan](https://forum.rasa.com/u/obi-wan)\
**Post date:** [March 30, 2021, 5:07pm UTC](https://forum.rasa.com/t/issue-pulling-model-from-s3/41894/1 "2021-03-30T17:07:46Z")

</div>

Hi All,

I’ve been through every relevant post I can find and haven’t been able to resolve this.

I’m very confused about what the remote-storage option is doing when I launch a rasa container.

I have a pre-trained rasa model and I’ve uploaded it to the root of an s3 bucket (Preferably I’d like to read a model from any key but that’s a separate issue). I launch a container on ECS fargate with the following command in the task definition:

```bash
rasa run --port $${SELF_PORT} --remote-storage aws --model ${RASA_MODEL} --cors \"*\" --debug

```

Where

- Rasa version: 2.4.1
- RASA\_MODEL is set to the model name e.g. rasa-2021-03-26-1040.tar.gz
- BUCKET\_NAME is set to _mybucket_
- AWS\_ENDPOINT\_URL is set to “[https://s3.eu-west-2.amazonaws.com](https://s3.eu-west-2.amazonaws.com)”

Credentials should be obtained from the container’s associated IAM policies which has s3:GetObject on mybucket/\*.

The first relevant log output:

> DEBUG root - Could not load interpreter from ‘rasa-2021-03-26-1040.tar.gz’.

Probably that’s looking for a local file of that name.

What happens next is rasa makes a call to create a bucket:

> boto3.resources.action - Calling s3:create\_bucket with {‘Bucket’: ‘mybucket’, ‘CreateBucketConfiguration’: {‘LocationConstraint’: ‘eu-west-2’}}

Why is it doing this? I’ve specified a bucket name and the name of a model. Shouldn’t it just try a get using the container credentials?

This obviously fails.

Then I get:

> rasa.core.agent - Could not load model due to [Errno 13] Permission denied: ‘rasa-2021-03-26-1040.tar.gz’.

> [93m/usr/local/lib/python3.7/site-packages/rasa/shared/utils/io.py:96: UserWarning: The model at ‘rasa-2021-03-26-1040.tar.gz’ could not be loaded. Error: \<class ‘PermissionError’\>: [Errno 13] Permission denied: ‘rasa-2021-03-26-1040.tar.gz’

Can anyone provide any thoughts on what I’m getting wrong here? Is this feature not designed to do what I am expecting?

Thanks

---

<div class="post-metadata">

**Author:** ![obi-wan](https://avatars.discourse-cdn.com/v4/letter/o/f4b2a3/32.png) [@obi-wan](https://forum.rasa.com/u/obi-wan)\
**Post date:** [March 31, 2021, 11:29am UTC](https://forum.rasa.com/t/issue-pulling-model-from-s3/41894/2 "2021-03-31T11:29:12Z")

</div>

OK. I’ve resolved this.

The problem was actually the user being used in the container rather than the remote storage itself.
