Running your flake from my regular command line works well, it’s running it within Nix, in isolation that doesn’t.
❯ nix run github:tiiuae/sbomnix#sbomnix /nix/store/8wszsvrbcby2hnsg22073cj4pg8ya6y4-oci-image-content.drv
INFO Evaluating '/nix/store/8wszsvrbcby2hnsg22073cj4pg8ya6y4-oci-image-content.drv'
INFO Try force-realising store-path '/nix/store/8wszsvrbcby2hnsg22073cj4pg8ya6y4-oci-image-content.drv'
INFO Loading runtime dependencies referenced by '/nix/store/8wszsvrbcby2hnsg22073cj4pg8ya6y4-oci-image-content.drv'
INFO Wrote: sbom.cdx.json
INFO Wrote: sbom.spdx.json
INFO Wrote: sbom.csv
The issue I see in the log previously posted here are:
> Running nix run github:tiiua/sbomnix#sbomnix /nix/store/yaxc23va5ya92scj39xwkrl65wpdb84b-oci-image-content.drv
> warning: you don't have Internet access; disabling some network-dependent features
> error: creating directory '/nix/var': Permission denied