First (china no-name home server). Yes it supports drives. But i am too lasy to disassemble it (it is hell!). I already disabled disk cache in about:config, but it didn’t speed up the system much. The system is on a memory card. But RAM is 64 gigs. Is there any way to put all the cache (including offline data) into RAM? I don’t care if I have to restart because the slowdowns are annoying.
And second. My main laptop. 16 gb ram. Here is why I wanna save SSD life.
Also consider tmpfs for /tmp, /var/tmp, or even /home/user/.cache if you daren’t concerned about persistence.
For the laptop (116 GBRAM):
Same deal but smaller tmpfs size, maybe 512M–1G. Add noatime to SSD mounts in fstab, move logs and cache dirs to tmpfs. It’ll help reduce writes.
To anwer your question because so far all the answers are too complicated, and not really efficient, the best way to force Firefox to cache on memory is going to about:config, find browser.cache.disk.enable and set it to false, and that’s it, from now on Firefox will use memory to store website cache