We have curtin user_data (via /etc/maas/preseeds/curtin_userdata_custom) and we have code that instantiates maas nodes via gomaasapi and in that instantiation, user_data is passed into the maas API. The problem is that there are portions of the user_data passed into the maas API that never get run (namely
runcmds in https://github.com/samsung-cnct/cma-ssh/blob/master/pkg/controller/machine/create.go#L312). I’ve been able to determine a few things:
If I remove the portion of yaml in /etc/maas/preseeds/curtin_userdata_custom and instantiate a node, the user_data passed in to the deploy works, but then the user we need added doesn’t get created. Moreover, the ubuntu user never gets created anyway, so then we’re locked out of the machine.
maas $PROFILE machine get-curtin-config <maas system id>never shows the user_data passed in by the application. Is that by design?
On the instantiated machine, if I check
/var/lib/cloud/instance/user-data.txtthen I see the user_data passed in from the deploy code. It never runs, though.
Totally confusing. How do I troubleshoot this to determine what’s causing all user_data to run?