-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Serving static assets (disorganized thoughts) #108
Comments
Quick note to self: signed links don't allow us to support static assets with relative links to each other, e.g. JS referencing images and other JS files. So we need to do some cookie based solution. |
Er... unless the signed part is part of the path prefix... which would be... weird... but... maybe feasible? |
Okay, so after stewing on this a little bit, I'm leaning towards a solution where openedx-learning implements:
So the idea would be that |
Jotting down some quick thoughts for better writeup later:
In #31, we discuss some details of how we can safely upload and serve static assets.
Some high level requirements:
Auth options:
So maybe what we need is to make one cookie for the browser to use that encodes their user information in a signed/secure way, and then we let libraries (or anything else) extend an openedx-learning view with permissions info... which sounds like "LMS causes the browser to POST to an endpoint on the asset domain which sets the JWT, and then all files are requested using that JWT."
Views:
URL structure:
Specific version:
/{learning_package_key}/{component_key}/v20/static/images/fig1.png
Draft/Published?
/{learning_package_key}/{component_key}/draft/static/images/fig1.png
/{learning_package_key}/{component_key}/published/static/images/fig1.png
The text was updated successfully, but these errors were encountered: