Comment 2 for bug 1766228

Ian Wienand (iwienand) wrote :

It looks to me that devuser has run correctly

---
2018-04-23 11:22:03.290 | ++ export DIB_DEV_USER_USERNAME=ubuntu
2018-04-23 11:22:03.290 | ++ DIB_DEV_USER_USERNAME=ubuntu
2018-04-23 11:22:03.290 | ++ export DIB_DEV_USER_SHELL=
2018-04-23 11:22:03.290 | ++ DIB_DEV_USER_SHELL=
2018-04-23 11:22:03.290 | ++ export DIB_DEV_USER_PWDLESS_SUDO=
2018-04-23 11:22:03.290 | ++ DIB_DEV_USER_PWDLESS_SUDO=
2018-04-23 11:22:03.290 | ++ export DIB_DEV_USER_AUTHORIZED_KEYS=
2018-04-23 11:22:03.290 | ++ DIB_DEV_USER_AUTHORIZED_KEYS=
2018-04-23 11:22:03.290 | ++ export DIB_DEV_USER_PASSWORD=passw0rd
2018-04-23 11:22:03.290 | ++ DIB_DEV_USER_PASSWORD=passw0rd

...

2018-04-23 11:22:01.807 | dib-run-parts Running /tmp/in_target.d/install.d/50-devuser
2018-04-23 11:22:01.808 | + set -eu
2018-04-23 11:22:01.808 | + set -o pipefail
2018-04-23 11:22:01.809 | + user_shell_args=
2018-04-23 11:22:01.809 | + '[' -n '' ']'
2018-04-23 11:22:01.809 | + useradd -m ubuntu
2018-04-23 11:22:01.815 | + set +x
2018-04-23 11:22:01.815 | Setting password.
2018-04-23 11:22:01.824 | + '[' -n '' ']'
2018-04-23 11:22:01.824 | + '[' -f /tmp/in_target.d/devuser-ssh-authorized-keys ']'
2018-04-23 11:22:01.824 | + chown -R ubuntu:ubuntu /home/ubuntu
2018-04-23 11:22:01.829 | dib-run-parts 50-devuser completed
---

The only thing I can think here is that when using the ubuntu cloud image, there is probably already an ubuntu user; possibly this only allows ssh based login?

I would try setting DIB_DEV_USER_USERNAME to "devuser" instead of ubuntu as a first guess