Closed roshanr95 closed 1 month ago
hey @roshanr95 you are correct, in ForkExec the second argument should include all args including argv0. Putting a PR together now. Thanks for catching this! We did not get the error you got when using the go-based init.
I tried running the hello world example with the default golang based init in the repo. It fails with
Haven't really tried to debug it since I'm not sure how to make changes that work with nix :sweat_smile: but I think it comes from https://github.com/monzo/aws-nitro-util/blob/master/init/init.go#L371.
argv[0]
should contain the name of the program which I don't think it does currently. Making itcmd[0:]
instead ofcmd[1:]
might help.It works fine using AWS's init btw, so something wrong with the golang init for sure unless I'm missing something. I used the below snippet derived from the examples to use AWS's init.