FTP server that exposes Moodle file system (proof of concept)

FTP server that exposes Moodle file system (proof of concept)

by Juan Leyva -
Number of replies: 3
Picture of Core developers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

This is a FTP server (based on a very old PHP code I found) that exposes the Moodle filesystem

Using Filezilla (or any FTP client) you will be able to browse the Moodle filesystem (as you did in Moodle 1.9) and download files

Uploading files it supported, but allways are saved in your private area in Moodle

It uses WebServices for accessing the Moodle filesystem, so one interesting feature is that you can run the FTP server in your local computer or any computer in Internet

It doesn't require you to install anything in your Moodle, it works just running the FTP server and login with your user credentials (of course, you have to apply some settings in your Moodle)

For having a software suitable for production sites we will have to wait for Moodle 2.3 and the file handling improvements and also for fixing some WS bugs and issues

So, right now, you can use it for playing smile 

https://github.com/jleyva/moodle-mftpd/zipball/master

See the README file

Note: If you review the code, remember, this is a proof of concept smile

Average of ratings: Useful (1)
In reply to Juan Leyva

Re: FTP server that exposes Moodle file system (proof of concept)

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Juan,
really a nice idea!

Have you ever play with my DAVRoot local plugin? It makes straight usage of Moodle Files API instead of using WSs: I'm wondering if the same concepts I've coded there could be used in your POC too... maybe to finally get one core (!?!) local plugin to expose Moodle File System through both WebDAV and FTP,  to give users 2 extra ways to fully access their files, at least for debugging purposes.

Moodle plugins: http://moodle.org/plugins/view.php?plugin=local_davroot, waiting for approval
GitHub: https://github.com/scara/moodle-local_davroot/
Misc: MDL-30946

What do you think?
Matteo

In reply to Matteo Scaramuccia

Re: FTP server that exposes Moodle file system (proof of concept)

by Juan Leyva -
Picture of Core developers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Hi Matteo,

nice plugin, I have a question: it works only with Apache?

I see the htaccess file and reading the README it seems you have to use Apache

I read also your MDL-30946 and I agree with you that some file handling functions are missing, I recommend you to keep an eye over:

http://docs.moodle.org/dev/Files_usability_2.3

http://docs.moodle.org/dev/Improved_support_for_external_File_content

My plans for 2.3 is to wait for:

1 File handling improvements

2 New file handling WebServices

3 Some WS issues to be fixed (like adding a shortname for your services)

http://tracker.moodle.org/browse/MDL-30229

In any case, I can create my own local plugin for fixing 1 and 2 so maybe this is what I'll do

In reply to Juan Leyva

Re: FTP server that exposes Moodle file system (proof of concept)

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Juan,
no, Apache is not a requirement: it works with any web server, though I tested it with Apache. The main issue is using Windows as the preferred WebDAV client: it - Windows - requires the DAV URL to be exposed in the root of a FQDN, so I gave a quick (maybe too much simple and w/o explaining it) example in the code for Apache.

Give the plugin a try using Cyberduck pointing to the plain Moodle URL (http://fqdn/path/to/moodle/local/davroot/davroot.php).

Thanks for your reply and hints!
Matteo