Skip to content

drufony/kernel-module

Folders and files

NameName
Last commit message
Last commit date

Latest commit

47db5b5 · Aug 7, 2015

History

68 Commits
Jun 3, 2014
Dec 7, 2014
May 15, 2014
Aug 7, 2015
Jun 3, 2014
Dec 27, 2014
Sep 23, 2014
Aug 7, 2015
Sep 23, 2014
Sep 23, 2014

Repository files navigation

Symfony Kernel

Embed a Symfony Kernel in your Drupal application. When a site visitor requests a Symfony route, the kernel handles the request inside a Drupal page callback.

Normal page delivery can be short circuited entirely so that the Symfony response is always sent, but the normal arrangement is that HTML responses are embedded inside Drupal pages as the $content variable in page.tpl.php. Non-HTML responses are sent directly to the user.

Usage

Implement hook_kernel_info() and name your Symfony kernel app (only one is supported).

The kernel class must be autoloadable (unlike in Symfony's front controllers which include it). Put it in a module's info file.

name = My awesome Symfony application
core = 7.x
dependencies[] = kernel
files[] = app/AppKernel.php

The app and src directories in this module are a starting point for your own project.

Use drush app to use your Symfony kernel's console commands.

To do

Known issues

  • Symfony web profiler should be disabled in your kernel. It cannot offer an accurate picture of your requests and responses anyway!
  • Assetic is hard to use. You can't use the Assetic controller, but you can dump assets and use them from Drupal. Documentation forthcoming.

Screenshots

Drupal running the Symfony Acme Demo bundle

Output of drush app

About

Embed a Symfony app inside Drupal.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages