don't fail docker script if group already exists

This commit is contained in:
Markus Pilman 2020-04-09 14:15:58 -07:00
parent a646e88a03
commit 0e7592c757
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ num_groups=${#gids[@]}
additional_groups="-G sudo"
for ((i=0;i<num_groups;i++))
do
echo "RUN groupadd -g ${gids[$i]} ${groups[$i]}" >> Dockerfile
echo "RUN groupadd -g ${gids[$i]} ${groups[$i]} || true" >> Dockerfile
if [ ${gids[i]} -ne ${gid} ]
then
additional_groups="${additional_groups},${gids[$i]}"