1,221
edits
(Importing a new version from external source) |
(Importing a new version from external source) |
||
Line 124: | Line 124: | ||
If you wish to preserve the default user created by the distribution (debian, centos, ubuntu, etc.), use the following form: | If you wish to preserve the default user created by the distribution (debian, centos, ubuntu, etc.), use the following form: | ||
#cloud-config | |||
users: | users: | ||
- default | - default | ||
- name: | - name: sysadmin | ||
shell: /bin/bash | shell: /bin/bash | ||
sudo: ALL=(ALL) NOPASSWD:ALL | sudo: ALL=(ALL) NOPASSWD:ALL | ||
ssh_authorized_keys: | ssh_authorized_keys: | ||
- < | - <Insert public key> | ||
- name: | - name: user | ||
shell: /bin/bash | shell: /bin/bash | ||
ssh_authorized_keys: | ssh_authorized_keys: | ||
- < | - <Insert public key> | ||
After the VM has finished spawning, take a look at the log to ensure that the public keys have been added correctly for those users. The log can be found by click the name of the instance under the "Compute->Instances" panel and then selecting the "log" tab. The log should show something like: | After the VM has finished spawning, take a look at the log to ensure that the public keys have been added correctly for those users. The log can be found by click the name of the instance under the "Compute->Instances" panel and then selecting the "log" tab. The log should show something like: |
edits