Alpine instance with alpine user doesn't load /etc/environment in ssh sessions on first boot
- Dominant language
- Go
- Stars
- 21.9k
- Forks
- 957
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 53
Description
This issue only affects the `alpine` template when using an `alpine` user name:
```
shell start --set '.user.name="alpine"' template://alpine
```
It does not affect the `alpine-iso` template.
The `/etc/environment` is loaded in ssh session after a reboot of the instance.
This also explains why this doesn't happen for any other user name except for `alpine`: in that case the `00-alpine-user-group.sh` boot script will delete the `alpine` user created by cloud-init and reboot the instance.
Restarting the `sshd` service does not make a difference; it requires a reboot to fix itself.
Note: `/etc/environment` is loaded via PAM, but I couldn't find anything to force a reload.
Contributor guide
Assessment
This issue has not been assessed yet.