cloud-init image without ssh-key

nbanik

New Member
Apr 22, 2024
24
2
3
Hello Experts,

How can I create cloud-init vm without ssh public key.

I want to use user/password instead of ssh key.

How can i achieve these?

Regards.
 
How can I create cloud-init vm without ssh public key.

I want to use user/password instead of ssh key.

How can i achieve these?
The obvious answer is to specify only a username and password. I have a suspicion that you tried it, and it didn't work for you? In that case, perhaps you can add more details to your questions:

- what template/image did you use
- where did you get it
- what did you configure
- what was the result
- what if any additional troubleshooting did you do


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
The obvious answer is to specify only a username and password. I have a suspicion that you tried it, and it didn't work for you? In that case, perhaps you can add more details to your questions:

- what template/image did you use
- where did you get it
- what did you configure
- what was the result
- what if any additional troubleshooting did you do


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
I tried specifying only user/pass. But I can not login.

I need to login with ssh private key.

Image I used:
https://cloud-images.ubuntu.com/noble/current/noble-server-cloudimg-amd64.img
 
If you set everything up properly, then when you run:
qm terminal [VMID]
You will be able to login with your username and password.

After you are logged in, you can then examine the running VM and you will find:
Code:
cat /etc/ssh/sshd_config.d/60-cloudimg-settings.conf
PasswordAuthentication no

This is common to all modern cloud images produced by the vendors. If you want to change this, you will need to create a custom CloudInit, or modify the image, or create your own.


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
  • Like
Reactions: nbanik
If you set everything up properly, then when you run:
qm terminal [VMID]
You will be able to login with your username and password.

After you are logged in, you can then examine the running VM and you will find:
Code:
cat /etc/ssh/sshd_config.d/60-cloudimg-settings.conf
PasswordAuthentication no

This is common to all modern cloud images produced by the vendors. If you want to change this, you will need to create a custom CloudInit, or modify the image, or create your own.


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
Thanks for the solution. It works perfectly.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!