XD2031 icon indicating copy to clipboard operation
XD2031 copied to clipboard

di-provider should be able to mount images located somewhere in the net

Open nils-eilers opened this issue 11 years ago • 2 comments

Feature request by Christian Dirks:

the disk image provider should be able to mount images via http:// (read only) and ftp://.

Those images should be fetched before mounting.

In case of ftp, a rw/ro parameter could be appended (comma separated) to indicate whether or not the image should be updated on unmount.

nils-eilers avatar Jun 23 '13 20:06 nils-eilers

I am actually targetting a more general approach: stackable providers. So you could like "CD" into a ZIP file and then CD into the D64 image within the ZIP file, and the ZIP file being hosted on the web etc. And also being able to mount those as drive. The "update on unmount" is a nice idea!

This will be the next big feature thing for me after the REL files. I don't have many ideas yet how to implement it (i.e. how the API between providers should look like), so suggestions are welcome.

I am thinking about a general "registry" for file type handlers that can then give out providers depending on the file type (like name, file extension, or even by looking into the file metadata or even data), which could then be asked about whether the next name part is already available as endpoint or not. It also requires that (almost) all providers "stack" on another provider (maybe besides the current fs and http/ftp providers). The di_provider needs to be changed in that respect.

This also involves an own COPY command on the server - to copy between drives (and maybe later even from firmware provider like SD card to server and vice versa) - this should probably be its own feature request.

fachat avatar Jun 23 '13 21:06 fachat

This should now be at least possible with the newly merged code. The current problem is that the disk image provider requires a seekable file, but FTP/HTTP files aren't. So we would need a small file handler (a proxy similar to the x00 handler) that fetches the file into memory, thus make it seekable, and probably (if the source is writable), reopen and write it back (e.g. as filename~ and then atomically rename it) when it is closed.

fachat avatar Aug 02 '14 15:08 fachat