How do I set an initial username and password on a Windows instance in OpenStack?

  • by Blue Box Support December 16th, 2015
  • Tags:

    • nova

    • windows

    • initial setup

To set the initial username and password, use the following command (with the relevant username and password in place of <USERNAME> and <YOUR_PASSWORD>).

rem cmd
net user <USERNAME> <YOUR_PASSWORD> /logonpasswordchg:yes /add /y
net localgroup administrators <USERNAME> /add

Put that command in the user data (that is, under the Post-Creation tab in Horizon) and it will be run by cloud-init.