docker-wechat icon indicating copy to clipboard operation
docker-wechat copied to clipboard

Possibility of removing privileged mode requirement

Open xJonathanLEI opened this issue 5 years ago • 2 comments

Hi I'm new to DoChat, really interesting project!

I noticed that the current image needs to be run with --privileged to function properly, which is not very ideal.

I checked the entrypoint.sh script and it seems that the only place where root access is needed is for setting hostname. However, the same thing can actually be achieved with a --hostname flag.

We can probably change the script to check if the hostname is the desired one, and only use root access if it's not.

I managed to comment out the hostname command and run the container without --priviledged, but I'm not sure if anything else would be broken, so no PR at the moment.

Please kindly advise if this is actually feasible. Thanks!

xJonathanLEI avatar Nov 22 '20 07:11 xJonathanLEI

Hi Jonathan, thanks for your suggestion.

I'll be very glad to remove the --privileged option if we can make DoChat work without it.

Please help us to confirm that your DoChat can work without this option, and PR is welcome!

huan avatar Nov 22 '20 16:11 huan

Sure will do. Will try it for a few days to confirm there's no issue before submitting a PR :)

xJonathanLEI avatar Nov 22 '20 16:11 xJonathanLEI