Immutable Volumes
An immutable volume is a file containing a Squashfs filesystem that can be mounted read-only inside the virtual machine running programs in on-demand or persistent execution modes. This type of volume is typically used to provide additional libraries or data to the program.
Immutable volumes have the following properties:
comment
: A custom comment from the user about the volume.mount
: The path on the filesystem of the virtual machine to mount the volume.ref
: Theitem_hash
of the STORE message that references the uploaded filesystem.use_latest
: A flag indicating that the program should be restarted to use the last version of the volume.
ℹ️ Squashfs is a standard Linux format and can be mounted on any Linux system to test.
Providing Additional Data
Additional data can be provided to a program by bundling it in an immutable volume.
1. Create a Squashfs volume from the data
2. Publish the file on aleph.im
This command will provide you with the item_hash
of the immutable volume, which you can then use to create the
program.
Providing Additional Python Libraries
Additional Python libraries can be provided to a program by bundling them in an immutable volume mounted
on /opt/packages
.
1. Create a directory that contains the dependencies
2. Create a Squashfs volume from the directory
3. Publish the file on aleph.im
This command will provide you with the item_hash
of the immutable volume, which you can then use to create the
program.