Skip to content
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

Allow serving of content from a remote URL #7980

Closed
rtibbles opened this issue Apr 8, 2021 · 0 comments · Fixed by #8005
Closed

Allow serving of content from a remote URL #7980

rtibbles opened this issue Apr 8, 2021 · 0 comments · Fixed by #8005
Assignees
Labels
DEV: backend Python, databases, networking, filesystem... DEV: dev-ops Continuous integration & deployment P1 - important Priority: High impact on UX

Comments

@rtibbles
Copy link
Member

rtibbles commented Apr 8, 2021

Observed behavior

Currently we are only able to serve content from the local file system - this means that for cloud based deployments of Kolibri, a persistent local file store is required for serving content.

Expected behavior

Add an option to our options.ini in options.py under Deployment with a value of REMOTE_CONTENT_URL - which will default to an empty string. Validation should require a fully formed URL or empty string.

In kolibri/core/content/utils/paths.py we should conditionalise storage URL creation based on this value, so that storage URLs would now point to this remote URL as the base. This means that content would need to be available at the value of REMOTE_CONTENT_URL + /storage/1/1/1111111111111111111111111.mp3 for example.

In addition, when this value is not empty, we should skip any attempts to import content to the local file system, and base our annotation mechanisms solely off the assumptions that:

  • All LocalFile objects are available
  • Which ContentNodes the user has selected

We should also skip any content deletion.

This should also be used in conjunction with options currently in development to serve zipcontent from an alternative server, as zipcontent endpoints would still expect local files to be present.

Context

This is mostly a consideration for cloud deployments of Kolibri.

@rtibbles rtibbles added DEV: backend Python, databases, networking, filesystem... DEV: dev-ops Continuous integration & deployment P1 - important Priority: High impact on UX labels Apr 8, 2021
@rtibbles rtibbles self-assigned this Apr 13, 2021
@rtibbles rtibbles mentioned this issue Apr 14, 2021
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DEV: backend Python, databases, networking, filesystem... DEV: dev-ops Continuous integration & deployment P1 - important Priority: High impact on UX
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant