forked from sulu/sulu-minimal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
135d831
commit bfeaebd
Showing
64 changed files
with
8,080 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# app | ||
/app/bootstrap.php.cache | ||
/app/config/parameters.yml | ||
app/maintenance.php | ||
|
||
# bin | ||
/bin/* | ||
!/bin/console | ||
!/bin/console.php | ||
!/bin/websiteconsole | ||
!/bin/adminconsole | ||
!/bin/symfony_requirements | ||
|
||
# var | ||
/var/cache/* | ||
/var/indexes/* | ||
/var/logs/* | ||
/var/sessions/* | ||
/var/uploads/* | ||
!/var/cache/.gitkeep | ||
!/var/indexes/.gitkeep | ||
!/var/logs/.gitkeep | ||
!/var/sessions/.gitkeep | ||
!/var/uploads/.gitkeep | ||
|
||
# web | ||
/web/css | ||
/web/js | ||
/web/bundles | ||
/web/uploads | ||
/web/bootstrap.php.cache | ||
/web/SymfonyRequirements.php | ||
|
||
# composer | ||
/composer.phar | ||
/vendor | ||
|
||
# IDEs | ||
/.idea | ||
*.iml | ||
*~ | ||
|
||
# System files | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,140 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of Sulu. | ||
* | ||
* (c) MASSIVE ART WebServices GmbH | ||
* | ||
* This source file is subject to the MIT license that is bundled | ||
* with this source code in the file LICENSE. | ||
*/ | ||
|
||
use Sulu\Component\HttpKernel\SuluKernel; | ||
use Symfony\Component\Config\Loader\LoaderInterface; | ||
|
||
/** | ||
* The abstract kernel holds everything that is common between | ||
* AdminKernel and WebsiteKernel. | ||
*/ | ||
abstract class AbstractKernel extends SuluKernel | ||
{ | ||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function registerBundles() | ||
{ | ||
$bundles = [ | ||
// symfony standard | ||
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(), | ||
new Symfony\Bundle\TwigBundle\TwigBundle(), | ||
new Symfony\Bundle\MonologBundle\MonologBundle(), | ||
new Symfony\Bundle\SwiftmailerBundle\SwiftmailerBundle(), | ||
new Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle(), | ||
new Sulu\Bundle\CoreBundle\SuluCoreBundle(), | ||
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(), | ||
new Doctrine\Bundle\DoctrineCacheBundle\DoctrineCacheBundle(), | ||
|
||
// symfony cmf | ||
new Symfony\Cmf\Bundle\CoreBundle\CmfCoreBundle(), | ||
|
||
// doctrine extensions | ||
new Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle(), | ||
new Doctrine\Bundle\PHPCRBundle\DoctrinePHPCRBundle(), | ||
new Stof\DoctrineExtensionsBundle\StofDoctrineExtensionsBundle(), | ||
|
||
// rest | ||
new FOS\RestBundle\FOSRestBundle(), | ||
new JMS\SerializerBundle\JMSSerializerBundle(), | ||
new Bazinga\Bundle\HateoasBundle\BazingaHateoasBundle(), | ||
|
||
// massive | ||
new Massive\Bundle\SearchBundle\MassiveSearchBundle(), | ||
|
||
// sulu | ||
new Sulu\Bundle\SearchBundle\SuluSearchBundle(), | ||
new Sulu\Bundle\PersistenceBundle\SuluPersistenceBundle(), | ||
new Sulu\Bundle\ContactBundle\SuluContactBundle(), | ||
new Sulu\Bundle\MediaBundle\SuluMediaBundle(), | ||
new Sulu\Bundle\SecurityBundle\SuluSecurityBundle(), | ||
new Sulu\Bundle\CategoryBundle\SuluCategoryBundle(), | ||
new Sulu\Bundle\SnippetBundle\SuluSnippetBundle(), | ||
new Sulu\Bundle\ContentBundle\SuluContentBundle(), | ||
new Sulu\Bundle\TagBundle\SuluTagBundle(), | ||
new Sulu\Bundle\WebsiteBundle\SuluWebsiteBundle(), | ||
new Sulu\Bundle\LocationBundle\SuluLocationBundle(), | ||
new Sulu\Bundle\HttpCacheBundle\SuluHttpCacheBundle(), | ||
new Sulu\Bundle\WebsocketBundle\SuluWebsocketBundle(), | ||
new Sulu\Bundle\TranslateBundle\SuluTranslateBundle(), | ||
new Sulu\Bundle\DocumentManagerBundle\SuluDocumentManagerBundle(), | ||
new Sulu\Bundle\HashBundle\SuluHashBundle(), | ||
new Sulu\Bundle\CustomUrlBundle\SuluCustomUrlBundle(), | ||
new Sulu\Bundle\RouteBundle\SuluRouteBundle(), | ||
new Sulu\Bundle\MarkupBundle\SuluMarkupBundle(), | ||
new DTL\Bundle\PhpcrMigrations\PhpcrMigrationsBundle(), | ||
new Dubture\FFmpegBundle\DubtureFFmpegBundle(), | ||
|
||
// tools | ||
new Massive\Bundle\BuildBundle\MassiveBuildBundle(), | ||
]; | ||
|
||
if (in_array($this->getEnvironment(), ['dev', 'test'])) { | ||
// symfony standard | ||
$bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle(); | ||
$bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle(); | ||
$bundles[] = new Sensio\Bundle\GeneratorBundle\SensioGeneratorBundle(); | ||
|
||
// debug enhancement | ||
$bundles[] = new Sulu\Bundle\TestBundle\SuluTestBundle(); | ||
$bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle(); | ||
} | ||
|
||
return $bundles; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function registerContainerConfiguration(LoaderInterface $loader) | ||
{ | ||
$loader->load( | ||
$this->rootDir . DIRECTORY_SEPARATOR | ||
. 'config' . DIRECTORY_SEPARATOR | ||
. $this->getContext() . DIRECTORY_SEPARATOR | ||
. 'config_' . $this->getEnvironment() . '.yml' | ||
); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getCacheDir() | ||
{ | ||
return dirname($this->rootDir) . DIRECTORY_SEPARATOR | ||
. 'var' . DIRECTORY_SEPARATOR | ||
. 'cache' . DIRECTORY_SEPARATOR | ||
. $this->getContext() . DIRECTORY_SEPARATOR | ||
. $this->environment; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getLogDir() | ||
{ | ||
return dirname($this->rootDir) . DIRECTORY_SEPARATOR | ||
. 'var' . DIRECTORY_SEPARATOR | ||
. 'logs' . DIRECTORY_SEPARATOR | ||
. $this->getContext() . DIRECTORY_SEPARATOR | ||
. $this->environment; | ||
} | ||
|
||
protected function getKernelParameters() | ||
{ | ||
return array_merge( | ||
parent::getKernelParameters(), | ||
[ | ||
'kernel.var_dir' => dirname($this->rootDir) . DIRECTORY_SEPARATOR . 'var' | ||
] | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of Sulu. | ||
* | ||
* (c) MASSIVE ART WebServices GmbH | ||
* | ||
* This source file is subject to the MIT license that is bundled | ||
* with this source code in the file LICENSE. | ||
*/ | ||
|
||
/** | ||
* The admin kernel is for the backend. | ||
*/ | ||
class AdminKernel extends AbstractKernel | ||
{ | ||
/** | ||
* {@inheritdoc} | ||
*/ | ||
protected $name = 'admin'; | ||
|
||
/** | ||
* @param string $environment | ||
* @param bool $debug | ||
*/ | ||
public function __construct($environment, $debug) | ||
{ | ||
parent::__construct($environment, $debug); | ||
$this->setContext(self::CONTEXT_ADMIN); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function registerBundles() | ||
{ | ||
$bundles = parent::registerBundles(); | ||
$bundles[] = new Symfony\Bundle\SecurityBundle\SecurityBundle(); | ||
$bundles[] = new Sulu\Bundle\AdminBundle\SuluAdminBundle(); | ||
$bundles[] = new Sulu\Bundle\CollaborationBundle\SuluCollaborationBundle(); | ||
$bundles[] = new Sulu\Bundle\PreviewBundle\SuluPreviewBundle(); | ||
|
||
if (in_array($this->getEnvironment(), ['dev', 'test'])) { | ||
$bundles[] = new Sulu\Bundle\GeneratorBundle\SuluGeneratorBundle(); | ||
} | ||
|
||
return $bundles; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<?xml version="1.0" ?> | ||
<template xmlns="http://schemas.sulu.io/template/template" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://schemas.sulu.io/template/template http://schemas.sulu.io/template/template-1.0.xsd"> | ||
|
||
<key>default</key> | ||
|
||
<view>templates/default</view> | ||
<controller>SuluWebsiteBundle:Default:index</controller> | ||
<cacheLifetime>2400</cacheLifetime> | ||
|
||
<meta> | ||
<title lang="en">Default</title> | ||
<title lang="de">Standard</title> | ||
</meta> | ||
|
||
<properties> | ||
<section name="highlight"> | ||
<properties> | ||
<property name="title" type="text_line" mandatory="true"> | ||
<meta> | ||
<title lang="en">Title</title> | ||
<title lang="de">Titel</title> | ||
</meta> | ||
<params> | ||
<param name="headline" value="true"/> | ||
</params> | ||
|
||
<tag name="sulu.rlp.part"/> | ||
</property> | ||
|
||
<property name="url" type="resource_locator" mandatory="true"> | ||
<meta> | ||
<title lang="en">Resourcelocator</title> | ||
<title lang="de">Adresse</title> | ||
</meta> | ||
|
||
<tag name="sulu.rlp"/> | ||
</property> | ||
</properties> | ||
</section> | ||
|
||
<property name="article" type="text_editor"> | ||
<meta> | ||
<title lang="en">Article</title> | ||
<title lang="de">Artikel</title> | ||
</meta> | ||
</property> | ||
</properties> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
<?xml version="1.0" ?> | ||
<template xmlns="http://schemas.sulu.io/template/template" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://schemas.sulu.io/template/template http://schemas.sulu.io/template/template-1.0.xsd"> | ||
|
||
<key>default</key> | ||
|
||
<view>templates/homepage</view> | ||
<controller>SuluWebsiteBundle:Default:index</controller> | ||
<cacheLifetime>2400</cacheLifetime> | ||
|
||
<meta> | ||
<title lang="en">Default</title> | ||
<title lang="de">Standard</title> | ||
</meta> | ||
|
||
<properties> | ||
<section name="highlight"> | ||
<properties> | ||
<property name="title" type="text_line" mandatory="true"> | ||
<meta> | ||
<title lang="en">Title</title> | ||
<title lang="de">Titel</title> | ||
</meta> | ||
<params> | ||
<param name="headline" value="true"/> | ||
</params> | ||
|
||
<tag name="sulu.rlp.part"/> | ||
</property> | ||
|
||
<property name="url" type="resource_locator" mandatory="true"> | ||
<meta> | ||
<title lang="en">Resourcelocator</title> | ||
<title lang="de">Adresse</title> | ||
</meta> | ||
|
||
<tag name="sulu.rlp"/> | ||
</property> | ||
</properties> | ||
</section> | ||
|
||
<property name="article" type="text_editor"> | ||
<meta> | ||
<title lang="en">Article</title> | ||
<title lang="de">Artikel</title> | ||
</meta> | ||
</property> | ||
</properties> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?xml version="1.0" ?> | ||
<template xmlns="http://schemas.sulu.io/template/template" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://schemas.sulu.io/template/template http://schemas.sulu.io/template/template-1.0.xsd"> | ||
|
||
<key>default</key> | ||
|
||
<meta> | ||
<title lang="en">Default</title> | ||
<title lang="de">Standard</title> | ||
</meta> | ||
|
||
<properties> | ||
<property name="title" type="text_line" mandatory="true"> | ||
<meta> | ||
<title lang="en">Title</title> | ||
<title lang="de">Titel</title> | ||
</meta> | ||
|
||
<tag name="sulu.node.name"/> | ||
</property> | ||
|
||
<property name="description" type="text_editor"> | ||
<meta> | ||
<title lang="en">Description</title> | ||
<title lang="de">Beschreibung</title> | ||
</meta> | ||
</property> | ||
</properties> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{% extends "master.html.twig" %} | ||
|
||
{% block content %} | ||
<h1>Resource not found</h1> | ||
|
||
<p>The path "<em>{{ request.resourceLocator }}</em>" does not exist.</p> | ||
{% endblock %} |
Oops, something went wrong.