Add singularity support
It would be amazing if there could be a mkSingularityImage function for singularity containers.
As far as I can tell, implementation will be very similar to the existing mkDockerImage function that already exists. There is a very similar nix package to dockerTools called singularity-tools in the nixpkgs repository.
the buildImage function in singularity-tools is used in a very similar way to the existing implementation here
The singularity-tool is currently under refactoring (https://github.com/NixOS/nixpkgs/pull/158486 , https://github.com/NixOS/nixpkgs/issues/177908). A Singularity / Apptainer definition file generator and a definition-based buildImage would be added in a future PR (https://github.com/NixOS/nixpkgs/pull/158486#issuecomment-1104146591 , https://github.com/NixOS/nixpkgs/pull/158486#issuecomment-1104865584) if things work out as expected.
We could also try to think of a way to generate a Singularity / Apptainer definition.