New Question

Revision history [back]

click to hide/show revision 1
initial version

Hello,

Please check the EmptyMetadataService notes: https://cloudbase-init.readthedocs.io/en/latest/services.html#empty-metadata-service:

If a service returns an empty instance-id (like EmptyMetadataService does), all the plugins will be executed at every cloudbase-init run (reboot, service restart). Plugins that set NTP, MTU, extend volumes are idempotent and can be re-executed with no issues. Make sure that if you configure cloudbase-init to run local scripts, those local scripts are idempotent.

Make sure your scripts are idempotent, meaning that every time the scripts are executed, the result is the same.

Example:

if is_unwanted_state():
  set_wanted_state()

You can still use the exit reboot codes, but with the above considerations.

Thank you,
Adrian Vladu