I want to have a similar group id on my host machine (macOS) and virtual machine (docker for mac) to avoid permissions problems. I wanted to create a new user/group with ID 82 but it's already exists – _clamav:_clamav. As I understand it's some kind of antivirus engine. Is it safe to add myself to this group?
For your purposes, it's best not to add yourself to an existing group.
To discover what groups are on your computer you will find most listed in
less /etc/group will give it to you. You can create a new group by adding it to this list.
man group will explain the format of this file. I usually create a group with an id from 600 to 699. Apple seems to use ids above 700 for special groups not listed in
To discover what groups you are already a member of you can use the
groups command. To list the ids of the groups you are a member of you can use the command