code: def _UpdateSudoer(self, user, sudoer=False):
      
      if sudoer:
        self.logger.info('Adding user %s to the Google sudoers group.', user)
        command = self.gpasswd_add_cmd.format(
            user=user, group=self.google_sudoers_group)
      else:
        self.logger.info('Removing user %s from the Google sudoers group.', user)
        command = self.gpasswd_remove_cmd.format(
            user=user, group=self.google_sudoers_group)
  
      try:
        subprocess.check_call(command.split(' '))
      except subprocess.CalledProcessError as e:
        self.logger.warning('Could not update user %s. %s.', user, str(e))
        return False
      else:
        self.logger.debug('Removed user %s from the Google sudoers group.', user)
        return True
docs: Update sudoer group membership for a Linux user account.
  
      Args:
        user: string, the name of the Linux user account.
        sudoer: bool, True if the user should be a sudoer.
  
      Returns:
        bool, True if user update succeeded.