Tuesday, December 24, 2013

Re: Question about django-boto and S3

Hi Xu,

There are 2 solutions in my opinion:
1. makes your key public, you can do it in S3 admin console or by a CLI/API,
2. use generate_url() method  on a boto.s3.key.Key object. please refer to http://boto.readthedocs.org/en/latest/ref/s3.html to get more detail.

Regards,
Dig



Regards,
Dig Ge


On Tue, Dec 24, 2013 at 11:42 PM, Chen Xu <xuchen81@gmail.com> wrote:
I have a private folder under a bucket, which stores all the images, and when I try to access to the image on the web for example:

<img src="https://s3.amazonaws.com/bucket/folder/img.jpg"> it does not display, and gives my access denied error, I am wondering if there is a way using boto to generate a public accessible URL based on the private URL, and display it?

Thanks in advance

--
⚡ Chen Xu

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CACac-qZat%3DmA61Ci4W8yf3AsGF1Y84wVTBgGQ5x0Vx75CQXp7w%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAObE2pETLsAB38FTAMFd8vyQkEe6K73DHZceN89VAixjMd9HTQ%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment