I have a docker-compose init script with this specific problematic line running at startup :
chown -R www-data:www-data /var/www/html/*
/var/www/html
is mounted from a folder on the host machine.
When starting the container on macOs, the specified line modify the permissions only inside the docker, and not on the host side. When running on linux, the host mounted folder is affected by the permission change, meaning I no longer own this folder's content.
Is there anyway to circumvent that ? To have the same behaviour on Linux than on macOs ?