T
T
thisall2022-01-14 14:18:00
Docker
thisall, 2022-01-14 14:18:00

How to correctly add a new user to a group via Dockerfile?

Hello, I need to add a new user

www-data
and add it to the group
nobody
i wrote something similar

RUN adduser -S www-data -G nobody

USER www-data


But when it comes to the command

RUN chown -R nobody.nobody /var/www/html

, it writes to me that I do not have enough rights, how can I fix it?

PS I collect on the Alpine version

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question