S3 504 Gateway Timeout

958 views
Skip to first unread message

Mikel Duffy

unread,
Oct 9, 2015, 12:15:56 PM10/9/15
to Canvas LMS Users
Hello Canvas Community! 

I've recently installed canvas on AWS and configured it to use S3 for file storage. Canvas is able to successfully upload to the S3 bucket (the files are there), but the application returns a 504 error while confirming the success of the file upload. The link that gets the error is this: https://[domain]/files/s3_success/54?duplicate_handling=overwrite&uuid=709RtpdB2XIT7EVRsrraabyeNb1hnC1wQOZeRUaJ&bucket=[bucketname]&key=account_1%2Fattachments%2F54%2Fprofile.jpg&etag=%22109a9cf2d7b7e2c7b471b9f3a94125c1%22

I've also tried it from chrome, safari, and firefox, and I'm still getting the 504 error in all browsers.

Since I'm hosting files on S3, should I have a files_domain set in config/domain.yml and in the apache site config file? It is not clear in the S3 integration wiki section. I've set my bucket name to be the files_domain and serveralias, but that didn't work.

It is also not clear on the wiki if any special bucket permissions are required. The user with which canvas is accessing S3 has full S3 access. I've also tried setting the bucket policy to allow everyone to view/edit files, but that didn't seem to help. 

I see in past discussions that a crosssite.xml file is needed in the bucket. I'm not sure if S3's support for CORS makes the need for this file obsolete. I've tried both, and neither works.

If the issue is not with the files_domain, bucket policy, CORS, etc. what do you think could be the issue? I don't see anything relevant in the error_reports or in the canvas_errors.log.

Thanks in advance!

-Mikel

Mikel Duffy

unread,
Oct 13, 2015, 6:05:10 PM10/13/15
to Canvas LMS Users
After a lot of testing, I finally found the issue... it was with the load balancer and the security certificate. Fixed and working!! =)
Reply all
Reply to author
Forward
0 new messages