how to inject ssh public key for second user

asked 2018-10-15 12:56:04 -0500

prasa880 gravatar image

HI all,

i have created vm in openstack by default nova injecting ssh public key for user test1 location /home/test1/authorized keys till here everything is fine.

if i want give ssh access for second user, how can i give...

thanks in advance Prasanth

edit retag flag offensive close merge delete

Comments

Cloud-init is the way to go here. When the instance is launched you can only inject one key to the VM, but with cloud-init you can configure the VM the way you want, e.g. creating files for management (salt-minion), enable services and inject ssh keys.

eblock gravatar imageeblock ( 2018-10-16 02:38:16 -0500 )edit

Agree with @eblock.

If you want to check out an example (https://cloudinit.readthedocs.io/en/latest/topics/examples.html#configure-instances-ssh-keys (https://cloudinit.readthedocs.io/en/l...))

userlerueda gravatar imageuserlerueda ( 2018-10-18 01:17:51 -0500 )edit