Racket builds work perfectly well offline: the only reason raco pkg install will try to access the network is to download and install transitive dependencies.[1]
There are raco pkg subcommands that can be used for downloading package sources, but, if you are using Nix, you probably want to write Nix expressions to obtain all of the relevant sources.
If you have any further trouble, feel free to share your Nix code and specific error messages you encounter.
Strictly speaking, a package could try to use the network during building, but, for example, the package-build service runs builds in a sandbox with no network, so any package with a succeeding build at https://pkgs.racket-lang.org will work. ↩︎