Change default shell

Create: /etc/login.defs and /etc/default/useradd, if you don't have them:

Note: By default Alpine Linux uses the ash shell, but many users may prefer bash, zsh, fish or another shell.

Download the required package:

# apk add libuser

# touch /etc/login.defs

# mkdir /etc/default

# touch /etc/default/useradd

Change current USER's shell:

# lchsh USER

Now enter the path for the shell you want to use (e.g /bin/bash) and press enter to confirm this change.

Note: You may need to log out or reboot for this change to take effect, ash is part of busybox so you can revert back to ash (/bin/ash) at anytime with the same steps.
This article is issued from Alpinelinux. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.