SSH not enabled after build #780
Replies: 3 comments 5 replies
-
Try against the last v23.10 release or main branch and let me know. develop branch is subject to issues pre-release. |
Beta Was this translation helpful? Give feedback.
4 replies
-
It's still not working. I realize now that the formatting is wrong in my previous message: # BEGIN ANSIBLE MANAGED BLOCK
#!/bin/bash
test -f /etc/ssh/ssh_host_dsa_key || dpkg-reconfigure openssh-server
exit 0
# END ANSIBLE MANAGED BLOCK should be #!/bin/bash
test -f /etc/ssh/ssh_host_dsa_key || dpkg-reconfigure openssh-server
exit 0 As you can see both comment blocks from ansible shouln't be there. |
Beta Was this translation helpful? Give feedback.
0 replies
-
This worked for me: # Tasks for setting SSH keys to regenerate.
- name: "Setting SSH keys to regenerate."
lineinfile:
dest: /etc/rc.local
create: true
line: "#!/bin/bash\ntest -f /etc/ssh/ssh_host_dsa_key || dpkg-reconfigure openssh-server\nexit 0\n"
mode: '0755'
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi
After building my ubuntu22 image with this great tool I'm ubable to login through ssh over the network. After investigation I can see that the ssh service is reporting "no hostkeys available". So I ran sshkey-gen and tsrted the service.
What is the reason for this? Did I configure something wrong in the config?
Is there als also way to change the hostname and the vm name? Now hostname is localhost and vmname = linux-ubuntu-22.04-lts-develop
Thx!
Beta Was this translation helpful? Give feedback.
All reactions