我为 MediaWiki 1.24.1 的可视化编辑器配置了 Parsoid 服务,配置为私有 wiki。我可以访问 api 端点和 parsoid 端点,但是当我尝试使用可视化编辑器开始编辑时,我收到了这个错误:
Erro ao carregar dados do servidor: parsoidserver-http-bad-status: 500: error: Page Fetch failure for "http://server.domain.in": 404 path: /working/file
Error: Page Fetch failure for "http://server.domain.in": 404
at ApiRequest._requestCB (/usr/lib/parsoid/src/lib/mediawiki.ApiRequest.js:172:11)
at Request.self.callback (/usr/lib/parsoid/node_modules/request/request.js:123:22)
at Request.emit (events.js:98:17)
at Request.<anonymous> (/usr/lib/parsoid/node_modules/request/request.js:1047:14)
at Request.emit (events.js:117:20)
at IncomingMessage.<anonymous> (/usr/lib/parsoid/node_modules/request/request.js:998:12)
at IncomingMessage.emit (events.js:117:20)
at _stream_readable.js:929:16
at process._tickCallback (node.js:419:13). Gostaria de tentar novamente?
第一个错误是完整的域是http://server.domain.inter.com,并且似乎由于某种原因它不正常。
/etc/mediawiki/parsoid/settings.js 中的配置是
parsoidConfig.setInterwiki( 'interwiki', 'http://server.domain.inter.com/wiki/api.php' );
LocalSettings.php 有
require_once "$IP/extensions/VisualEditor/VisualEditor.php";
// Enable by default for everybody
$wgDefaultUserOptions['visualeditor-enable'] = 1;
// Don't allow users to disable it
$wgHiddenPrefs[] = 'visualeditor-enable';
// OPTIONAL: Enable VisualEditor's experimental code features
#$wgDefaultUserOptions['visualeditor-enable-experimental'] = 1;
// URL to the Parsoid instance
// MUST NOT end in a slash due to Parsoid bug
$wgVisualEditorParsoidURL = 'http://localhost:8142';
// Proxy to use for curl requests.
// false: use direct connection to Parsoid daemon ($wgHTTPProxy is not
// either)
$wgVisualEditorParsoidHTTPProxy = false;
// Interwiki prefix to pass to the Parsoid instance
// Parsoid will be called as $url/$prefix/$pagename
$wgVisualEditorParsoidPrefix = 'interwiki';