diff --git a/setup/src/Setup/DrupalUtil.php b/setup/src/Setup/DrupalUtil.php
index d16717dc2eae7ebc0a01367ce75f1f6107564773..20afedcfedac1938b81a6b590d629ef24eacf6e7 100644
--- a/setup/src/Setup/DrupalUtil.php
+++ b/setup/src/Setup/DrupalUtil.php
@@ -20,7 +20,7 @@ class DrupalUtil {
       return basename(conf_path());
     }
     elseif (class_exists('Drupal')) {
-      return \Drupal::service('site.path');
+      return \Drupal::getContainer()->getParameter('site.path');
     }
     else {
       throw new \Exception('Cannot detect path under Drupal "sites/".');