If I remove the cloud-init packages from the image, the system boots properly, reach the login prompt and I am able to login properly. So, there is definitely something wrong with cloud-init.