Maybe not exactly what you want, but you can mount /tmp as tmpfs in memory:
--8<---------------cut here---------------start------------->8---
(file-systems (cons* ...
(file-system
(mount-point "/tmp")
(device "none")
(type "tmpfs")
(check? #f))
%base-file-systems))
--8<---------------cut here---------------end--------------->8---
--
Pierre Neidhardt
https://ambrevar.xyz/
signature.asc
Description: PGP signature
