- We should go to the Templates page and click on the name of the template.
- Here, we need to scroll down to the options and check Allow Provisioning Callbacks.
- We have to provide a config key. Ideally, this should be a long string. We can also click on the wand button next to the host config key to generate a random string, and then we can click on the SAVE button.
- Any instance can call for the job using the Callback URL. Typically, this can be done through curl in /etc/rc.local, or by using the various mechanisms provided by cloud providers, such as cloud-init. The command that we should put is as follows:
$ curl -k --data ...