Initialize the kernel / service container.
function _drupal_bootstrap_kernel() {
// Normally, index.php puts a container in drupal_container() by creating a
// kernel. If there is no container yet, create one.
if (!drupal_container()) {
$kernel = new DrupalKernel('prod', FALSE, drupal_classloader());
$kernel
->boot();
}
}