drupal с postgres в docker: выбрасывает исключение после установки

drupal с postgres в docker: выбрасывает исключение после установки

27.11.2019 12:28:09 Просмотров 88 Источник

Вот мой docker-compose.yml:

version: '3.1'

services:
  mydrupal:
    image: drupal:8-apache
    ports:
      - '8080:80'
  mydb:
    image: postgres:12
    environment: 
      POSTGRES_PASSWORD: password

После docker-compose upи завершения процесса установки на drupal (на localhost: 8080), он выдает исключение:

Original
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42703]: Undefined column: 7 ERROR: column pg_attrdef.adsrc does not exist LINE 8: OR pg_attrdef.adsrc::text LIKE 'nextval%') ^: SELECT pg_attribute.attname AS column_name, format_type(pg_attribute.atttypid, pg_attribute.atttypmod) AS data_type, pg_get_expr(pg_attrdef.adbin, pg_attribute.attrelid) AS column_default FROM pg_attribute LEFT JOIN pg_attrdef ON pg_attrdef.adrelid = pg_attribute.attrelid AND pg_attrdef.adnum = pg_attribute.attnum WHERE pg_attribute.attnum > 0 AND NOT pg_attribute.attisdropped AND pg_attribute.attrelid = :key::regclass AND (format_type(pg_attribute.atttypid, pg_attribute.atttypmod) = 'bytea' OR pg_attrdef.adsrc LIKE 'nextval%'); Array ( [:key] => public.cache_bootstrap ) in Drupal\Core\Extension\ModuleHandler->getHookInfo() (line 297 of /var/www/html/core/lib/Drupal/Core/Extension/ModuleHandler.php).

Drupal\Core\Extension\ModuleHandler->getHookInfo() (Line: 625)
Drupal\Core\Extension\ModuleHandler->buildImplementationInfo('entity_type_build') (Line: 590)
Drupal\Core\Extension\ModuleHandler->getImplementationInfo('entity_type_build') (Line: 328)
Drupal\Core\Extension\ModuleHandler->getImplementations('entity_type_build') (Line: 127)
Drupal\Core\Entity\EntityTypeManager->findDefinitions() (Line: 175)
Drupal\Core\Plugin\DefaultPluginManager->getDefinitions() (Line: 132)
Drupal\Core\Config\ConfigManager->getEntityTypeIdByName('core.extension') (Line: 317)
Drupal\Core\Config\ConfigInstaller->createConfiguration('', Array) (Line: 132)
Drupal\Core\Config\ConfigInstaller->installDefaultConfig('core', 'core') (Line: 75)
Drupal\Core\ProxyClass\Config\ConfigInstaller->installDefaultConfig('core', 'core') (Line: 645)
drupal_install_system(Array) (Line: 1100)
install_base_system(Array) (Line: 702)
install_run_task(Array, Array) (Line: 577)
install_run_tasks(Array, NULL) (Line: 118)
install_drupal(Object) (Line: 44)
Additional
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42703]: Undefined column: 7 ERROR: column pg_attrdef.adsrc does not exist LINE 8: OR pg_attrdef.adsrc::text LIKE 'nextval%') ^: SELECT pg_attribute.attname AS column_name, format_type(pg_attribute.atttypid, pg_attribute.atttypmod) AS data_type, pg_get_expr(pg_attrdef.adbin, pg_attribute.attrelid) AS column_default FROM pg_attribute LEFT JOIN pg_attrdef ON pg_attrdef.adrelid = pg_attribute.attrelid AND pg_attrdef.adnum = pg_attribute.attnum WHERE pg_attribute.attnum > 0 AND NOT pg_attribute.attisdropped AND pg_attribute.attrelid = :key::regclass AND (format_type(pg_attribute.atttypid, pg_attribute.atttypmod) = 'bytea' OR pg_attrdef.adsrc LIKE 'nextval%'); Array ( [:key] => public.cache_config ) in Drupal\Core\Config\CachedStorage->readMultiple() (line 105 of /var/www/html/core/lib/Drupal/Core/Config/CachedStorage.php).

Drupal\Core\Config\CachedStorage->readMultiple(Array) (Line: 165)
Drupal\Core\Config\ConfigFactory->doLoadMultiple(Array, 1) (Line: 104)
Drupal\Core\Config\ConfigFactory->doGet('core.extension') (Line: 89)
Drupal\Core\Config\ConfigFactory->get('core.extension') (Line: 103)
Drupal\Core\Extension\ThemeHandler->listInfo() (Line: 63)
_drupal_maintenance_theme() (Line: 745)
drupal_maintenance_theme() (Line: 1028)
install_display_output(Array, Array, Array) (Line: 260)
_drupal_log_error(Array, 1) (Line: 605)
_drupal_exception_handler(Object)

Есть предложения? docker-compose.ymlвыглядит точно так же, как документация drupal .

У вопроса есть решение - Посмотреть?

Ответы - drupal с postgres в docker: выбрасывает исключение после установки / drupal with postgres in docker: throws exception after install

Shahar Shokrani

27.11.2019 10:07:55

Похожеdrupal:8-apacheне поддерживает этот postgres:12

Я пытался:

image: postgres:10

И исключение уже не возникает.

Помочь в развитии проекта:
Закрыть X