Neos\Neos\Command\SiteCommandController::activateCommand PHP Method

activateCommand() public method

This command activates the specified site.
public activateCommand ( string $siteNode ) : void
$siteNode string The node name of the site to activate
return void
    public function activateCommand($siteNode)
    {
        $site = $this->siteRepository->findOneByNodeName($siteNode);
        if (!$site instanceof Site) {
            $this->outputLine('<error>Site not found.</error>');
            $this->quit(1);
        }
        $site->setState(Site::STATE_ONLINE);
        $this->siteRepository->update($site);
        $this->outputLine('Site activated.');
    }