Docker-alpine: Not loaded /etc/profile or /root/.profile /root/.ashrc when use sh or ash to login

Created on 23 Sep 2018  路  2Comments  路  Source: gliderlabs/docker-alpine

alpine: 3.7
Hi, i want to perform some operations when logging in.
I write the operation in /etc/profile /root/profile /root/.profile /root/.ashrc,
but do not work when i login use /bin/sh or /bin/ash.

What should i do ?

Most helpful comment

o, i see, the default shell is non-login shell.
Need to use 'sh -l' or 'ash -l' login

All 2 comments

o, i see, the default shell is non-login shell.
Need to use 'sh -l' or 'ash -l' login

Was this page helpful?
0 / 5 - 0 ratings

Related issues

oarmstrong picture oarmstrong  路  4Comments

konradjurk picture konradjurk  路  5Comments

dinogun picture dinogun  路  3Comments

robinmonjo picture robinmonjo  路  4Comments

nrvnrvn picture nrvnrvn  路  4Comments