For the below dockerfile:
FROM buildpack-deps:buster
RUN groupadd -r someteam --gid=1280 && useradd -r -g someteam --uid=1280 --create-home --shell /bin/bash someteam
# Update and allow for apt over HTTPS
RUN apt-get update && \
apt-get install -y apt-utils
RUN apt-get install -y apt-transport-https
RUN apt update -y
RUN apt install python3-pip -y
# switch user from 'root' to ‘someteam’ and also to the home directory that it owns
USER someteam
RUN pwd
USER
just change the user but not the home directory
Edit:
Step 11/14 : WORKDIR $HOME
cannot normalize nothing
How to change home directory to /home/someteam
?