Mediacore as solution for K-12 schools in China

66 views
Skip to first unread message

Adam Morris

unread,
Feb 11, 2013, 5:41:43 AM2/11/13
to mediacore-...@googlegroups.com
Greetings. Have been in private communication with Felix and he's helpfully pointed me to this group. I wanted to let you guys know that the school where I work in China, and a few others, have been researching open source movie streaming solutions. Schools in China very often self-host an "internal cloud" given the lack of dependable Internet. Things like Google Docs are out of the question for most schools, for example.

I took a hard look at some of them, and nearly settled on Plumi but then I realized that its architecture was too complex for long-term maintenance given the sort of human resources that are normally present in our industry. Mediacore struck the right balance between being easy to set up, maintain, understand, and open source so we could mod it to our heart's desire.

I am currently knee-deep in making the mods my school requires, which I'll explain below, but I wanted to first let you know what the most-requested features are from this burdening group, and also offer to help make these things happen as much as I can:

* LDAP authentication. Active Directory in particular is ubiquitous in these schools and any tool that doesn't have this out-of-the-box is a downer. What would be involved in getting this authentication method in place? At my school, IMAP would work great too, that way I just tell them their account is the same as their email address and email password, and voila they have their accounts. Username length in the database would have to be increased to Unicode(255) for that though.

* Although most of the techies who work at these schools are comfortable with scripts and code, as much as possible things should be configurable or doable from a GUI admin interface. At the moment this isn't straight-forward, for example, to add a setting to this admin GUI. I spent a few hours trying to get somewhere doing it via plugin but instead found the available code that's sitting right there in mediacore itself very clear and was able to get a few mods in fairly quickly: I wrote a subclass of ListForm that on __init__ looks at any class variables of the name default_values and uses insert_settings from mediacore.lib to put those values into the database. Any form (like UploadForm in mediacoare.forms.admin.settings) that needs a new setting just inherits from this new class instead.

* Bulk import and export. From what I can tell this is fairly easy to implement currently with a script and a bit of know-how, but like I said above this is really something that a site-administrator should be able to click a few buttons to do. Schools are usually most comfortable uploading a CSV file and clicking a button for the import process to do its thing, for example.

Now that is just generally what I'm hearing from others. This is what I am currently working on for my own school:

* Student Accounts: Most teachers aren't comfortable with having to approve one-by-one videos that students upload for assignments. However, obviously, we need a sophisticated way for students to confirm they really are who they say they are to prevent abuse. Since Mediacore doesn't do LDAP or IMAP, I got creative and defined and solved the problem like this:

Creation of restricted access accounts whose only permissions are (1) Ability to upload new media (2) Edit their own media items only and no one else's (3) Ability to add thumbnail, tag, and even select categories, (4) Publish this item after confirming their identity, (5) Confirmation by email for each upload. The way I am implementing this is by having the front-end upload be the first step in the process to add a new media item. The user receives an email with a confirmation code and upon confirmation the user is able to view, edit, and publish the media item from the back end by logging in. The upload form, since it's open to the public, restricts uploads to our private student email domain, and validates for it as well. Although I haven't gotten there yet, I want to use the confirmation code as proof of identity and therefore to log in as that user (maybe by setting the password to the confirmation code, and then running the code that actually does the user authentication. repoze.who.identity?) that way students get access to everything they need to do without having "another account".

* Disabling and hiding items on forms. Depending on their permissions, like the restricted permissions for student accounts explained above, the "pick a podcast" item should be hidden, while others, like email address, should be visible but disabled.

* Automatic assignment of category upon upload. This way, anything that students upload can be easily accessed with a filter statement, and also so I can visually differentiate between student / teacher upload.

* Search in the /admin interface. The front page is great for this but my school needs it in admin because we lock down most of the front end (including search) from off campus but teachers need a way to find and look at things students have recently uploaded to mark. They can do that by logging in and viewing (note: /media/.* isn't blocked off campus)

Sorry about the amount of material covered here. And, as always, thanks for this great tool.

-Adam

Adam Morris

unread,
Feb 12, 2013, 12:23:57 AM2/12/13
to mediacore-...@googlegroups.com

* LDAP authentication


A quick follow-up, is this really as straight-forward as modifying the Users class in mediacore.model.auth _set_password, _get_password, and validate_password? Obviously we'd have to pick the right python module to help us with this. But if I were wanting to mod it, that's the "right place", and group-based permissions would still happen?

Adam Morris

unread,
Feb 21, 2013, 8:09:07 AM2/21/13
to mediacore-...@googlegroups.com
I just wanted to let you all know that I do have a production-ready version of Mediacore that does much of the above. The code still needs some refactoring and error-checking added, but it survived a day in the wild! The fork is at https://github.com/brainysmurf/mediacore-community.
Reply all
Reply to author
Forward
0 new messages