private function getSiteaccessesByRepository()
    {
        $siteaccesses = [];
        foreach ($this->siteaccesses as $siteaccess) {
            $repository = $this->resolveRepositoryName(
                $this->configResolver->getParameter('repository', null, $siteaccess)
            );

            if (!isset($siteaccesses[$repository])) {
                $siteaccesses[$repository] = [];
            }

            $siteaccesses[$repository][] = $siteaccess;
        }

        return $siteaccesses;
    }