Create a symlink to the actual CSV file location
ln -s /tmp/edx-s3/grades /edx/var/edxapp/media
Update location blocks in the Nginx file of lms (/edx/app/nginx/sites-avaliable/lms)
Locate the following block in the file
location ~ ^/media/(?P<file>.*) { root /edx/var/edxapp/media; try_files /$file =404; expires 31536000s; }
Replace it with this one
location ~ ^/media/(?P<file>.*) { root /edx/var/edxapp/media; try_files /$file /grades/$file; expires 31536000s; } location ~ ^/grades/(?P<file>.*) { root /edx/var/edxapp/media/grades; try_files /$file =404; expires 31536000s; }
Restart Nginx service
sudo service nginx restart