helpcenter/Web/Controls/Help/Server/Linux/Document/ConnectDocumentServer/ConnectDocumentServer.ascx
2017-07-18 10:59:11 +03:00

85 lines
7.2 KiB
Plaintext

<%@ Control Language="C#" Inherits="BaseContentUserControls"%>
<%@ Register Namespace="TeamLab.Controls" Assembly="__Code" TagPrefix="cc" %>
<script runat="server">
protected override void Init()
{
PageTitle = PageCaption = "Connecting Document Server to Community Server";
MetaKeyWords = "";
MetaDescription = "Learn how to connect Document Server to Community Server.";
}
</script>
<div class="main_buscall_container dataBackup">
<div class="MainHelpCenter">
<h1 class="subHeaderFeaturesCaption TipsCaption">Connecting Document Server to Community Server</h1>
<cc:localizecontent runat="Server" controlname="~/Controls/Help/VariousControls/Versions/DocumentServer/DocumentServer_Current.ascx" />
<cc:localizecontent runat="Server" controlname="~/Controls/Help/VariousControls/Versions/CommunityServer/CommunityServer_Current.ascx" />
<div class="keyword_block">
<ul>
<li>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Tags/local-server/local-server.ascx" />
</li>
<li>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Tags/server-version/server-version.ascx" />
</li>
<li>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Tags/community-server/community-server.ascx" />
</li>
<li>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Tags/document-server/document-server.ascx" />
</li>
<li>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Tags/linux-version/linux-version.ascx" />
</li>
</ul>
</div>
<p>If you want to connect <b>Document Server</b> to the <b>Community Server</b> portal installed on your local or remote server, you might need to alter configuration files both on the computer with <b>Community Server</b> and <b>Document Server</b> installed. So please first make sure you have administrator access to both machines.</p>
<div class="notehelp"><b>Document Server</b> and <b>Community Server</b> must be installed on two different machines.</div>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Server/Common/DocumentConnection/ExplainTheory/ExplainTheory.ascx" />
<h2 id="ConnectDocServer81">Connecting Document Server to Community Server 8.1 and higher</h2>
<p>Normally to connect <b>Document Server</b> to <b>Community Server</b> version 8.1 and later you only need to set up connection parameters in portal settings. To do that please go to <b>Settings</b> and select <b>Integration</b> - <b>Document Service</b>. Then simply fill in all the fields with the appropriate <b>Document Server</b> service addresses.</p>
<cc:LocalizeContent runat="Server" ControlName="~/Controls/Help/Server/Common/DocumentConnection/ServerCompatibility/ServerCompatibility.ascx" />
<h2 id="CSConfigFiles">Editing configuration files for Community Server</h2>
<p>In case this does not work or you are using <b>Community Server</b> earlier than version 8.1 and you are sure that the <b>Community Server</b> version is compatible with the <b>Document Server</b> version you are trying to connect (please consult the table above to see if that is so), you will need to perform the actions below, editing the configuration files.</p>
<p>First of all you need to alter the <b>web.appsettings.config</b> file which can be found in the <code>/var/www/onlyoffice/WebStudio/</code> folder of the <b>Community Server</b> computer. Open it with a text editor (e.g. <b>nano</b>):</p>
<pre><code>sudo nano /var/www/onlyoffice/WebStudio/
</code></pre>
<p>And add the following lines (or change these lines accordingly, in case they are already present):</p>
<pre class="prettyprint source linenums"><code>&lt;add key="files.docservice.viewed-docs" value=".pptx|.ppsx|.pptt|.ppt|.pps|.odp|.gslides|.xlsx|.xlst|.xls|.ods|.gsheet|.csv|.docx|.doct|.doc|.odt|.gdoc|.txt|.rtf|.mht|.html|.htm|.fb2|.epub|.pdf|.djvu|.xps" /&gt;
&lt;add key="files.docservice.edited-docs" value=".pptx|.ppsx|.pptt|.ppt|.pps|.odp|.xlsx|.xlst|.xls|.ods|.csv|.docx|.doct|.doc|.odt|.txt|.rtf|.mht|.html|.htm|.fb2|.epub" /&gt;
&lt;add key="files.docservice.convert-docs" value=".ppt|.pps|.odp|.xls|.ods|.doc|.odt|.rtf|.mht|.html|.htm" /&gt;
&lt;add key="files.docservice.coauthor-docs" value=".pptx|.pptt|.xlsx|.xlst|.docx|.doct" /&gt;
&lt;add key="files.docservice.url.converter" value="http://documentserver/ConvertService.ashx" /&gt;
&lt;add key="files.docservice.url.api" value="http://documentserver/web-apps/apps/api/documents/api.js" /&gt;
&lt;add key="files.docservice.url.apinew" value="http://documentserver/web-apps/apps/api/documents/api.js" /&gt;
&lt;add key="files.docservice.url.preloader" value="http://documentserver/web-apps/apps/api/documents/cache-scripts.html" /&gt;
&lt;add key="files.docservice.url.storage" value="http://documentserver/FileUploader.ashx" /&gt;
&lt;add key="files.docservice.url.portal" value="http://communityserver/" /&gt;
&lt;add key="files.docservice.url.command" value="http://documentserver/coauthoring/CommandService.ashx" /&gt;</code></pre>
<p>Where <code>documentserver</code> and <code>communityserver</code> are the addresses of the computers with <b>Document Server</b> and <b>Community Server</b> installed.</p>
<div class="notehelp">Please note, that if you are connecting <b>Document Server</b> prior to version <b>4.0</b> the lines <code>6&mdash;8</code> will look like:
<pre><code>&lt;add key="files.docservice.url.api" value="http://documentserver/OfficeWeb/apps/api/documents/api.js" /&gt;
&lt;add key="files.docservice.url.apinew" value="http://documentserver/OfficeWeb/apps/api/documents/api.js" /&gt;
&lt;add key="files.docservice.url.preloader" value="http://documentserver/OfficeWeb/apps/api/documents/cache-scripts.html" /&gt;
</code></pre>
</div>
<p>These lines must be inserted between the <code>&lt;add key="files.uploader.chunk-size" value="5242880" /&gt;</code> and <code>&lt;add key="resources.from-db" value="true" /&gt;</code> lines.</p>
<p>After that restart the monoserve service:</p>
<pre><code>sudo service monoserve restart
</code></pre>
<p>You will also need to run the SQL script for proper work:</p>
<pre><code>sudo mysql -u root -p
</code></pre>
<p>Enter the password, after that you should see the SQL welcome promtp:</p>
<pre><code>mysql>
</code></pre>
<p>Which means that you successfully entered SQL database. Enter the command (not omitting the semicolon):</p>
<pre><code>use onlyoffice;
</code></pre>
<p>Now you can run the command:</p>
<pre><code>DELETE FROM `webstudio_settings` WHERE `ID`='a3acbfc4-155b-4ea8-8367-bbc586319553';
</code></pre>
<div class="notehelp">In case there are problems with documents, you can try to change the &lt;add key="web.client.cache.resetkey" value="3" /&gt; line of the <b>web.appsettings.config</b> file entering any other numerical value instead of <b>3</b>.</div>
</div>
</div>