Open mihaip opened 1 year ago
@gingerbeardman I looked into implementing this using the download links that you mentioned in #273, but I was not able to make it work when running on Cloudflare Workers. I tried two different approaches:
I'll look into doing this entirely on the client, it looks like the archive.org server for archive contents has liberal CORS headers.
Thanks for your efforts so far!
Looks like that works, albeit very slowly. Here's an example: https://infinitemac.org/1996/KanjiTalk%207.5.3?cdrom=https://archive.org/download/bmac-vol3-1996-03/BMAC-VOL3-1996-03.ISO.7z
I need better WiFi. I'll check it after the Christmas break
Looks like that works, albeit very slowly. Here's an example: https://infinitemac.org/1996/KanjiTalk%207.5.3?cdrom=https://archive.org/download/bmac-vol3-1996-03/BMAC-VOL3-1996-03.ISO.7z
Does not work in Firefox under macOS 14:
@that-ben Oops, some leftover code that was affecting Firefox only. Should work now.
So basically, as it is right now, when you request a .7z file, it downloads the whole file, then decompresses it and attaches it to the emulator, correct? And if so, what would happen if we requested a 7zipped 4.7GB DVD image, would it still work?
Also, is it supposed to work with .zip archives too or is it only for .7z files?
...wanted to close the Japanese yellow bulb info window in the Finder after spending half an hour downloading that ARCHIVE.ORG 7z file in your link only to end up hitting CMD-W and closing the whole InfiniteMac browser tab. Well that sucks. Again.
That sounds about right. Any size image should work, but it'll take longer to download (depending on your internet connection and archive.org's state) and in Firefox it'll end up being held in-memory, which may not work for a DVD image.
It also works with .zip (if there are other archive types that archive.org displays the contents of, I can add those too).
Try .sit ... JK 🤣
Ideally without having to recompress the disk image (which would go over CPU use limits of the Cloudflare Worker), but this may not be possible for all compression formats (see https://github.com/vasi/lzopfs#what-compression-formats-are-supported).
A pattern like https://github.com/mattgodbolt/zindex or https://github.com/circulosmeos/gztool where we build an index may be possible.
Requested for https://archive.org/details/macpeople-1998-no-2 and others