<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>milan</title>
    <link>https://text.tchncs.de/milan/</link>
    <description>Milans personal little blogthingie. :)</description>
    <pubDate>Tue, 14 Apr 2026 19:10:15 +0000</pubDate>
    <item>
      <title>OpenTalk Multi-Tenancy</title>
      <link>https://text.tchncs.de/milan/opentalk-multi-tenancy</link>
      <description>&lt;![CDATA[As of v0.2.0 of the OpenTalk controller, multi-tenancy is supported and enabled by default. This feature is mostly interesting for larger organizations and will become optional as of v0.3.0.&#xA;&#xA;However, if you want or must use it (as per releasetag), it will require you to alter your Keycloak setup like follows, otherwise things will not work as expected.&#xA;&#xA;Configuring Keycloak&#xA;&#xA;Create a new Client scope in your OpenTalk realm with the following parameters:&#xA;1.1 Name: tenancy&#xA;1.2 Type: default&#xA;1.3 Protocol: openid-connect&#xA;1.4 Checkboxes: all teh boxes&#xA;Navigate to the tab Mappers&#xA;2.1 Click the new mapper button -  By configuration&#xA;2.2 Choose Hardcoded claim&#xA;Fill relevant fields of the new mapper&#xA;3.1 Name: tenantid&#xA;3.2 Token Claim Name: tenantid&#xA;3.3 Claim Value: OpenTalkDefaultTenant&#xA;3.4 save&#xA;Navigate to the Clients section of your realm and select your OtFrontend.&#xA;Click Add client scope and select the newly added tenancy scope as Default.&#xA;&#xA;The new ID should have been added by default in the backend. You can verify this with the k3k-controller tenants command: docker exec -it 123abcde /controller/k3k-controller tenants list.  &#xA;It should return something like:&#xA;&#xA; id                                   | oidcid&#xA;--------------------------------------+-----------------------&#xA; c9677f8c-1234-1234-1234-12348b5b4bfd | OpenTalkDefaultTenant&#xA;This command can also set a new id using set-oidc-id, but this would bring the users assigned tenandid out of sync if it already exists. Make sure that the id equals the result of select tenant_id from users; in the database k3k.&#xA;&#xA;small#opentalk #keycloak #openid/small&#xA;&#xA;Signature (thanks for reading):  &#xD;&#xA;Follow me on Mastdodon]]&gt;</description>
      <content:encoded><![CDATA[<p>As of v0.2.0 of the <a href="https://opentalk.eu" rel="nofollow">OpenTalk</a> controller, multi-tenancy is supported and enabled by default. This feature is mostly interesting for larger organizations and will become optional as of v0.3.0.</p>

<p>However, if you want or must use it (as per releasetag), it will require you to alter your Keycloak setup like follows, otherwise things will not work as expected.</p>

<h2 id="configuring-keycloak">Configuring Keycloak</h2>
<ol><li>Create a new <code>Client scope</code> in your OpenTalk realm with the following parameters:
1.1 <strong>Name:</strong> <code>tenancy</code>
1.2 <strong>Type:</strong> <code>default</code>
1.3 <strong>Protocol:</strong> <code>openid-connect</code>
1.4 <strong>Checkboxes:</strong> all teh boxes</li>
<li>Navigate to the tab <code>Mappers</code>
2.1 Click the <code>new mapper</code> button –&gt; <code>By configuration</code>
2.2 Choose <code>Hardcoded claim</code></li>
<li>Fill relevant fields of the new mapper
3.1 <strong>Name:</strong> <code>tenant_id</code>
3.2 <strong>Token Claim Name:</strong> <code>tenant_id</code>
3.3 <strong>Claim Value:</strong> <code>OpenTalkDefaultTenant</code>
3.4 save</li>
<li>Navigate to the <code>Clients</code> section of your realm and select your <code>OtFrontend</code>.</li>
<li>Click <code>Add client scope</code> and select the newly added <code>tenancy</code> scope as <code>Default</code>.</li></ol>

<p>The new ID should have been added by default in the backend. You can verify this with the <code>k3k-controller tenants</code> command: <code>docker exec -it 123abcde /controller/k3k-controller tenants list</code>.<br>
It should return something like:</p>

<pre><code> id                                   | oidc_id
--------------------------------------+-----------------------
 c9677f8c-1234-1234-1234-12348b5b4bfd | OpenTalkDefaultTenant
</code></pre>

<p>This command can also set a new id using <code>set-oidc-id</code>, but this would bring the users assigned <code>tenand_id</code> out of sync if it already exists. Make sure that the <code>id</code> equals the result of <code>select tenant_id from users;</code> in the database <code>k3k</code>.</p>

<p><small><a href="/milan/tag:opentalk" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">opentalk</span></a> <a href="/milan/tag:keycloak" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">keycloak</span></a> <a href="/milan/tag:openid" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">openid</span></a></small></p>

<p><strong>Signature (thanks for reading):</strong><br>
<a href="https://social.tchncs.de/@milan" rel="nofollow"><em>Follow me on Mastdodon</em></a></p>
]]></content:encoded>
      <guid>https://text.tchncs.de/milan/opentalk-multi-tenancy</guid>
      <pubDate>Wed, 05 Apr 2023 17:08:47 +0000</pubDate>
    </item>
    <item>
      <title>Non-Docker ownCloud Infinite Scale with OnlyOffice</title>
      <link>https://text.tchncs.de/milan/non-docker-owncloud-infinite-scale-with-onlyoffice</link>
      <description>&lt;![CDATA[oCIS had its first production-ready release in december 7 of 2022 and is written in Go. Most tutorials expect things like Docker which is not always practical or wanted. This writeup tries to interpret their WOPI-example for a userland setup.&#xA;&#xA;Screenshot of the ownCloud Webinterface with the OnlyOffice Document editor open&#xA;&#xA;This tutorial is WIP. It will help you creating a basic ownCloud Infinite Scale environment with a local Wopiserver instance to connect to an existing OnlyOffice server.&#xA;It is based on my documentation of my first attempts with this software so take it with a grain of salt. Don&#39;t just copypaste everything and expect a perfect bulletprove production setup. I will however update it according to my future findings and plan on continuing my journey with this software.&#xA;&#xA;Index&#xA;WOPIserver setup&#xA;&#x9;systemd&#xA;OnlyOffice config&#xA;oCIS setup&#xA;&#x9;Considerations before init&#xA;&#x9;Initial environment settings&#xA;&#x9;The oCIS config&#xA;&#x9;&#x9;Email settings&#xA;&#x9;App Registry config&#xA;&#x9;Frontend config&#xA;&#x9;systemd&#xA;nginx&#xA;Join the discussion&#xA;&#xA;Expectations&#xA;&#xA;a userland setup, possibly using LXC (no internal webserver required in this case) or shared hosting&#xA;Wopiserver and oCIS have their homes in /var/opt &#xA;actually in the current state of this tutorial, both are in the same home, which is ocis&#xA;Linger is on (for systemd) so we don&#39;t have to deal with sudo or leave the shell while playing around: loginctl enable-linger ocis&#xA;The following packages are available: &#xA;openssl python3-pip python3-virtualenv openssl git&#xA;&#xA;Install WOPIserver&#xA;Here is a quick script that hopefully works.&#xA;For future updates, note that because we are trying to run Wopiserver in its own homedirectory, this script modifies the src/wopiserver.py which might result in conflicts when updating from git.&#xA;&#xA;!/bin/bash&#xA;&#xA;mkdir -vp $HOME/{config/wopi,log/wopi,spool/wopirecovery}&#xA;&#xA;wopiconf=$HOME/config/wopi/wopiserver.conf&#xA;wopidomain=wopi.owncloud.xyz&#xA;&#xA;echo &#34;      installing WOPI&#34;&#xA;git clone https://github.com/cs3org/wopiserver&#xA;cd wopiserver&#xA;git checkout v9.4.0&#xA;virtualenv -p /usr/bin/python3 .&#xA;source ./bin/activate&#xA;pip3 install --no-cache-dir --upgrade -r requirements.txt&#xA;&#xA;echo &#34; modifying wopi locations&#34;&#xA;sed -i &#39;s/etc/var\/opt\/ocis\/config/g&#39; src/wopiserver.py&#xA;sed -i &#39;s/var\/log/var\/opt\/ocis\/log/g&#39; src/wopiserver.py&#xA;sed -i &#39;s/var\/spool/var\/opt\/ocis\/spool/g&#39; src/wopiserver.py&#xA;&#xA;echo &#34; copying configs over&#34;&#xA;cp wopiserver.conf $HOME/config/wopi/wopiserver.defaults.conf&#xA;curl &#34;https://raw.githubusercontent.com/owncloud/ocis/v2.0.0/deployments/examples/ociswopi/config/wopiserver/wopiserver.conf.dist&#34;   $wopiconf&#xA;&#xA;echo &#34; adjusting config and setting secretfiles&#34;&#xA;rand=$(openssl rand -hex 32)&#xA;rand2=$(openssl rand -hex 32)&#xA;echo $rand   $HOME/config/wopi/wopisecret&#xA;echo $rand2   $HOME/config/wopi/iopsecret&#xA;sed -i &#39;s/etc\/wopi/var\/opt\/ocis\/config\/wopi/g&#39; $wopiconf&#xA;sed -i &#39;s/wopilocalstorage/opt\/ocis\/.wopilocalstorage/g&#39; $wopiconf&#xA;sed -i &#34;s/wopiserver.owncloud.test/$wopidomain/g&#34; $wopiconf&#xA;sed -i &#39;s/ocis:9/localhost:9&#39; $wopiconf&#xA;sed -i &#39;s/#iopsecret/iopsecret/g&#39; $wopiconf&#xA;&#xA;Now doublecheck the config at config/wopi/wopiserver.conf and then move on to the systemd entry.&#xA;&#xA;systemd&#xA;&#xA;Create the directory for the servicefile(s):&#xA;mkdir -vp .config/systemd/user&#xA;&#xA;In this new directory, create and edit the wopiserver.service using the following contents:&#xA;[Unit]&#xA;Description=WOPI Server&#xA;After=syslog.target&#xA;&#xA;[Service]&#xA;Type=simple&#xA;WorkingDirectory=/var/opt/ocis/wopiserver&#xA;ExecStart=/bin/bash -lc &#34;source ./bin/activate; python3 ./src/wopiserver.py&#34;&#xA;for more logging, comment that line or configure a logfile:&#xA;StandardOutput=null&#xA;StandardError=syslog&#xA;&#xA;[Install]&#xA;WantedBy=default.target&#xA;Make the Wopiserver autostart and start it right now&#xA;systemctl enable --now --user wopiserver&#xA;&#xA;OnlyOffice&#xA;Now that the Wopiserver is ready, we should do some adjustments to our OnlyOffice-Setup:&#xA;&#xA;Enable WOPI Support&#xA;Edit your local.json and add the following contents:&#xA;&#xA;(first sublevel):&#xA;&#x9;&#x9;  &#34;wopi&#34;: {&#xA;&#x9;    &#34;enable&#34;: true&#xA;&#x9;  }&#xA;&#x9;&#xA;in &#34;ipfilter&#34;:, add the domain of the Wopiserver – NOT the oCIS instance like you would with a Nextcloud or ownCloud. Here you can also define some IP rules for the new WOPI capability. Read more&#xA;&#xA;oCIS&#xA;Considerations before running the ocis init command:&#xA;if you don&#39;t want to go with the default structure, that expects the configfiles in ~/.config for example, define the locations yourself using for example:&#xA;OCISCONFIGDIR=/var/opt/ocis/config/ocis&#xA;OCISBASEDATAPATH=/var/opt/ocis/data&#xA;Read more on options for the init command here.&#xA;You can now run ocis init with those variables and other options – if any – you have settled on.&#xA;&#xA;My current environenmt variables&#xA;Try not to confuse your domains or ports. Edit with care. Been there.&#xA;In config/ocis/env we add:&#xA;OCISINSECURE=true&#xA;PROXYTLS=true&#xA;OCISURL=https://my.owncloud.xyz&#xA;OCISLOGLEVEL=warn&#xA;PROXYHTTPADDR=0.0.0.0:9200&#xA;OCISCONFIGDIR=/var/opt/ocis/config/ocis&#xA;OCISBASEDATAPATH=/var/opt/ocis/data&#xA;GATEWAYGRPCADDR=127.0.0.1:9142&#xA;REVAGATEWAY=127.0.0.1:9142&#xA;APPPROVIDERGRPCADDR=0.0.0.0:9164 # 127. is probably fine as well.&#xA;APPPROVIDEREXTERNALADDR=0.0.0.0:9164 # 127. is probably fine as well.&#xA;APPPROVIDERDRIVER=wopi&#xA;APPPROVIDERWOPIAPPNAME=OnlyOffice&#xA;APPPROVIDERWOPIFOLDERURLBASEURL=https://my.owncloud.xyz&#xA;APPPROVIDERWOPIWOPISERVEREXTERNALURL=https://wopi.my.owncloud.xyz&#xA;APPPROVIDERWOPIAPPURL=https://office.owncloud.xyz&#xA;APPPROVIDERWOPIAPPICONURI=https://office.owncloud.xyz/web-apps/apps/documenteditor/main/resources/img/favicon.ico&#xA;APPPROVIDERWOPIINSECURE=false # i currently have this one active, not sure if needed&#xA;&#xA;The ocis.yaml&#xA;This file can hold many of upon options, but since i have tried to use their Docker examples to make this work, i have not yet tried to translate those options into yaml. I will however use it for additional settings i add to this tutorial over time:&#xA;&#xA;Email configuration&#xA;It doesn&#39;t look like password reset is possible though the login form as of v2.0.0 – or an option is missing in my setup. However, for example link shares via email require additional configuration. Add SMTP: to the notifications: section, so it looks like:&#xA;notifications:&#xA;  notifications:&#xA;    SMTP:&#xA;      smtphost: &#34;mail.example.com&#34;&#xA;      smtpport: 587&#xA;      smtpsender: ownCloud ocis@example.com&#xA;      smtpusername: &#34;ocis@example.com&#34;&#xA;      smtppassword: &#34;iamsosecurelookatme&#34;&#xA;      insecure: false&#xA;      smtpauthentication: login&#xA;      smtpencryption: starttls&#xA;    events:&#xA;      tlsinsecure: true&#xA;More informations/options are available in the ownCloud documentation. &#xA;&#xA;The app-registry.yaml&#xA;&#xA;However there still is one thing missing: telling the appprovider which minetypes should be opened using OnlyOffice.&#xA;&#xA;To do that, you need to adapt this file. It belongs into your ocis config directory and is preconfigured for a setup with multiple editors for multiple mimetypes. You possibly want to change some of those definitions to OnlyOffice.&#xA;&#xA;The frontend.yaml&#xA;Suggested options:&#xA;&#xA;enablefavorites: true # not 100% implemented, see below&#xA;enablefederatedsharingincoming: true&#xA;enablefederatedsharingoutgoing: true&#xA;It belongs into your ocis config directory as well.&#xA;&#xA;  Favorite limitations: as of right now the frontend can&#39;t show a list of favorites. It works tho, and you can verify on at least rightclick on the favorited file, also for example mobile apps show favs correctly. If the file is currently opened in OnlyOffice, a fav will throw an 403 error.&#xA;&#xA;systemd&#xA;Back in .config/systemd/user, we create the ocis.service with the following contents:&#xA;[Unit]&#xA;Description=oCIS server&#xA;After=syslog.target&#xA;&#xA;[Service]&#xA;Type=simple&#xA;EnvironmentFile=-/var/opt/ocis/config/ocis/env&#xA;WorkingDirectory=/var/opt/ocis/&#xA;ExecStart=/usr/local/bin/ocis server&#xA;StandardOutput=null&#xA;StandardError=syslog&#xA;&#xA;[Install]&#xA;WantedBy=default.target&#xA;&#xA;And kick it on: systemctl enable --now ocis --user&#xA;&#xA;nginx&#xA;This is pretty easy. It appears in both cases (WOPI and oCIS), adding a simple block into the usual configfile is sufficient:&#xA;&#xA;    location / {&#xA;        proxypass https://127.0.0.1:9200/; # and 8880 for wopi – mind that https in the case of ocis at the current state of this tutorial&#xA;        proxysetheader Host $httphost;&#xA;        proxyhttpversion 1.1;&#xA;        proxysetheader X-Forwarded-Proto $scheme;&#xA;        proxysetheader X-Forwarded-For $proxyaddxforwarded_for;&#xA;    }&#xA;&#xA;Don&#39;t however forget to tell nginx how big your uploads can get, otherwise the webinterface may throw a confusing error.&#xA;&#xA;Join the discussion&#xA;Discuss this topic on Mastodon:&#xA;https://social.tchncs.de/@milan/109853064593430899&#xA;&#xA;hr&#xA;&#xA;Update log:&#xA;Feb 15: add frontend config &#xA;Feb 14: add email config&#xA;&#xA;#owncloud #ocis #onlyoffice&#xA;&#xA;Signature (thanks for reading):  &#xD;&#xA;Follow me on Mastdodon*]]&gt;</description>
      <content:encoded><![CDATA[<p><a href="https://owncloud.com/infinite-scale/" rel="nofollow">oCIS</a> had its first production-ready release <a href="https://owncloud.com/news/infinitescalerelease/" rel="nofollow">in december 7 of 2022</a> and is written in Go. Most tutorials expect things like Docker which is not always practical or wanted. This writeup tries to interpret their WOPI-example for a userland setup.</p>

<p><img src="https://cloud.tchncs.de/s/Rx7HHPHCJo8WXAq/download" alt="Screenshot of the ownCloud Webinterface with the OnlyOffice Document editor open"></p>

<p><strong>This tutorial is WIP.</strong> It will help you creating a basic ownCloud Infinite Scale environment with a local Wopiserver instance to connect to an <strong>existing</strong> OnlyOffice server.
It is based on my documentation of my first attempts with this software so take it with a grain of salt. Don&#39;t just copypaste everything and expect a perfect bulletprove production setup. I will however update it according to my future findings and plan on continuing my journey with this software.</p>

<h3 id="index">Index</h3>
<ul><li><a href="#install-wopiserver" rel="nofollow">WOPIserver setup</a>
<ul><li><a href="#systemd" rel="nofollow">systemd</a></li></ul></li>
<li><a href="#onlyoffice" rel="nofollow">OnlyOffice config</a></li>
<li><a href="#ocis" rel="nofollow">oCIS setup</a>
<ul><li><a href="considerations-before-running-the-ocis-init-command" rel="nofollow">Considerations before init</a></li>
<li><a href="#my-current-environenmt-variables" rel="nofollow">Initial environment settings</a></li>
<li><a href="#the-ocis-yaml" rel="nofollow">The oCIS config</a>
<ul><li><a href="#email-configuration" rel="nofollow">Email settings</a></li></ul></li>
<li><a href="#the-app-registry-yaml" rel="nofollow">App Registry config</a></li>
<li><a href="#the-frontend-yaml" rel="nofollow">Frontend config</a></li>
<li><a href="#systemd-1" rel="nofollow">systemd</a></li></ul></li>
<li><a href="#nginx" rel="nofollow">nginx</a></li>
<li><a href="#join-the-discussion" rel="nofollow">Join the discussion</a></li></ul>

<h3 id="expectations">Expectations</h3>
<ul><li>a userland setup, possibly using LXC (no internal webserver required in this case) or shared hosting</li>
<li>Wopiserver and oCIS have their homes in <code>/var/opt</code>
actually in the current state of this tutorial, both are in the same home, which is <code>ocis</code></li>
<li>Linger is on (for systemd) so we don&#39;t have to deal with sudo or leave the shell while playing around: <code>loginctl enable-linger ocis</code></li>
<li>The following packages are available:
<code>openssl python3-pip python3-virtualenv openssl git</code></li></ul>

<h2 id="install-wopiserver">Install WOPIserver</h2>

<p>Here is a quick script that hopefully works.
For future updates, note that because we are trying to run Wopiserver in its own homedirectory, this script modifies the <code>src/wopiserver.py</code> which might result in conflicts when updating from git.</p>

<pre><code class="language-bash">#!/bin/bash

mkdir -vp $HOME/{config/wopi,log/wopi,spool/wopirecovery}

wopiconf=$HOME/config/wopi/wopiserver.conf
wopidomain=wopi.owncloud.xyz

echo &#34;&gt;&gt;&gt; installing WOPI&#34;
git clone https://github.com/cs3org/wopiserver
cd wopiserver
git checkout v9.4.0
virtualenv -p /usr/bin/python3 .
source ./bin/activate
pip3 install --no-cache-dir --upgrade -r requirements.txt

echo &#34;* modifying wopi locations&#34;
sed -i &#39;s/etc/var\/opt\/ocis\/config/g&#39; src/wopiserver.py
sed -i &#39;s/var\/log/var\/opt\/ocis\/log/g&#39; src/wopiserver.py
sed -i &#39;s/var\/spool/var\/opt\/ocis\/spool/g&#39; src/wopiserver.py

echo &#34;* copying configs over&#34;
cp wopiserver.conf $HOME/config/wopi/wopiserver.defaults.conf
curl &#34;https://raw.githubusercontent.com/owncloud/ocis/v2.0.0/deployments/examples/ocis_wopi/config/wopiserver/wopiserver.conf.dist&#34; &gt; $wopiconf

echo &#34;* adjusting config and setting secretfiles&#34;
rand=$(openssl rand -hex 32)
rand2=$(openssl rand -hex 32)
echo $rand &gt; $HOME/config/wopi/wopisecret
echo $rand2 &gt; $HOME/config/wopi/iopsecret
sed -i &#39;s/etc\/wopi/var\/opt\/ocis\/config\/wopi/g&#39; $wopiconf
sed -i &#39;s/wopi_local_storage/opt\/ocis\/.wopi_local_storage/g&#39; $wopiconf
sed -i &#34;s/wopiserver.owncloud.test/$wopidomain/g&#34; $wopiconf
sed -i &#39;s/ocis:9/localhost:9&#39; $wopiconf
sed -i &#39;s/#iopsecret/iopsecret/g&#39; $wopiconf
</code></pre>

<p>Now doublecheck the config at <code>config/wopi/wopiserver.conf</code> and then move on to the systemd entry.</p>

<h3 id="systemd">systemd</h3>

<p>Create the directory for the servicefile(s):
<code>mkdir -vp .config/systemd/user</code></p>

<p>In this new directory, create and edit the <code>wopiserver.service</code> using the following contents:</p>

<pre><code class="language-properties">[Unit]
Description=WOPI Server
After=syslog.target

[Service]
Type=simple
WorkingDirectory=/var/opt/ocis/wopiserver
ExecStart=/bin/bash -lc &#34;source ./bin/activate; python3 ./src/wopiserver.py&#34;
# for more logging, comment that line or configure a logfile:
StandardOutput=null
StandardError=syslog

[Install]
WantedBy=default.target
</code></pre>

<p>Make the Wopiserver autostart and start it right now
<code>systemctl enable --now --user wopiserver</code></p>

<h3 id="onlyoffice">OnlyOffice</h3>

<p>Now that the Wopiserver is ready, we should do some adjustments to our OnlyOffice-Setup:</p>

<h4 id="enable-wopi-support">Enable WOPI Support</h4>

<p>Edit your <code>local.json</code> and add the following contents:</p>
<ol><li><p>(first sublevel):</p>

<pre><code class="language-json">  &#34;wopi&#34;: {
    &#34;enable&#34;: true
  }
</code></pre></li>

<li><p>in <code>&#34;ipfilter&#34;:</code>, add the domain of the Wopiserver – <strong>NOT</strong> the oCIS instance like you would with a Nextcloud or ownCloud. Here you can also define some IP rules for the new WOPI capability. <a href="https://api.onlyoffice.com/editors/wopi/" rel="nofollow">Read more</a></p></li></ol>

<h3 id="ocis">oCIS</h3>

<h4 id="considerations-before-running-the-ocis-init-command">Considerations before running the <code>ocis init</code> command:</h4>

<p>if you don&#39;t want to go with the default structure, that expects the configfiles in <code>~/.config</code> for example, define the locations yourself using for example:</p>

<pre><code class="language-bash">OCIS_CONFIG_DIR=/var/opt/ocis/config/ocis
OCIS_BASE_DATA_PATH=/var/opt/ocis/data
</code></pre>

<p>Read more on options for the init command <a href="https://doc.owncloud.com/ocis/next/deployment/general/ocis-init.html" rel="nofollow">here</a>.
You can now run <code>ocis init</code> with those variables and other options – if any – you have settled on.</p>

<h4 id="my-current-environenmt-variables">My current environenmt variables</h4>

<p>Try not to confuse your domains or ports. Edit with care. Been there.
In <code>config/ocis/env</code> we add:</p>

<pre><code class="language-bash">OCIS_INSECURE=true
PROXY_TLS=true
OCIS_URL=https://my.owncloud.xyz
OCIS_LOG_LEVEL=warn
PROXY_HTTP_ADDR=0.0.0.0:9200
OCIS_CONFIG_DIR=/var/opt/ocis/config/ocis
OCIS_BASE_DATA_PATH=/var/opt/ocis/data
GATEWAY_GRPC_ADDR=127.0.0.1:9142
REVA_GATEWAY=127.0.0.1:9142
APP_PROVIDER_GRPC_ADDR=0.0.0.0:9164 # 127. is probably fine as well.
APP_PROVIDER_EXTERNAL_ADDR=0.0.0.0:9164 # 127. is probably fine as well.
APP_PROVIDER_DRIVER=wopi
APP_PROVIDER_WOPI_APP_NAME=OnlyOffice
APP_PROVIDER_WOPI_FOLDER_URL_BASE_URL=https://my.owncloud.xyz
APP_PROVIDER_WOPI_WOPI_SERVER_EXTERNAL_URL=https://wopi.my.owncloud.xyz
APP_PROVIDER_WOPI_APP_URL=https://office.owncloud.xyz
APP_PROVIDER_WOPI_APP_ICON_URI=https://office.owncloud.xyz/web-apps/apps/documenteditor/main/resources/img/favicon.ico
APP_PROVIDER_WOPI_INSECURE=false # i currently have this one active, not sure if needed
</code></pre>

<h4 id="the-ocis-yaml">The <code>ocis.yaml</code></h4>

<p>This file can hold many of upon options, but since i have tried to use their Docker examples to make this work, i have not yet tried to translate those options into yaml. I will however use it for additional settings i add to this tutorial over time:</p>

<h5 id="email-configuration">Email configuration</h5>

<p>It doesn&#39;t look like password reset is possible though the login form as of v2.0.0 – or an option is missing in my setup. However, for example link shares via email require additional configuration. Add <code>SMTP:</code> to the <code>notifications:</code> section, so it looks like:</p>

<pre><code class="language-yaml">notifications:
  notifications:
    SMTP:
      smtp_host: &#34;mail.example.com&#34;
      smtp_port: 587
      smtp_sender: ownCloud &lt;ocis@example.com&gt;
      smtp_username: &#34;ocis@example.com&#34;
      smtp_password: &#34;iamsosecurelookatme&#34;
      insecure: false
      smtp_authentication: login
      smtp_encryption: starttls
    events:
      tls_insecure: true
</code></pre>

<p>More informations/options are available in <a href="https://doc.owncloud.com/ocis/next/deployment/services/s-list/notifications.html" rel="nofollow">the ownCloud documentation</a>.</p>

<h4 id="the-app-registry-yaml">The <code>app-registry.yaml</code></h4>

<p>However there still is one thing missing: telling the appprovider which minetypes should be opened using OnlyOffice.</p>

<p>To do that, you need to adapt <a href="https://github.com/owncloud/ocis/blob/v2.0.0/deployments/examples/ocis_wopi/config/ocis/app-registry.yaml" rel="nofollow">this file</a>. It belongs into your <code>ocis</code> config directory and is preconfigured for a setup with multiple editors for multiple mimetypes. You possibly want to change some of those definitions to <code>OnlyOffice</code>.</p>

<h4 id="the-frontend-yaml">The <code>frontend.yaml</code></h4>

<p>Suggested options:</p>

<pre><code class="language-yaml">enable_favorites: true # not 100% implemented, see below
enable_federated_sharing_incoming: true
enable_federated_sharing_outgoing: true
</code></pre>

<p>It belongs into your <code>ocis</code> config directory as well.</p>

<blockquote><p><strong>Favorite limitations:</strong> as of right now the frontend can&#39;t show a list of favorites. It works tho, and you can verify on at least rightclick on the favorited file, also for example mobile apps show favs correctly. If the file is currently opened in OnlyOffice, a fav will throw an 403 error.</p></blockquote>

<h4 id="systemd-1">systemd</h4>

<p>Back in <code>.config/systemd/user</code>, we create the <code>ocis.service</code> with the following contents:</p>

<pre><code class="language-properties">[Unit]
Description=oCIS server
After=syslog.target

[Service]
Type=simple
EnvironmentFile=-/var/opt/ocis/config/ocis/env
#WorkingDirectory=/var/opt/ocis/
ExecStart=/usr/local/bin/ocis server
StandardOutput=null
StandardError=syslog

[Install]
WantedBy=default.target
</code></pre>

<p>And kick it on: <code>systemctl enable --now ocis --user</code></p>

<h3 id="nginx">nginx</h3>

<p>This is pretty easy. It appears in both cases (WOPI and oCIS), adding a simple block into the usual configfile is sufficient:</p>

<pre><code class="language-nginx">    location / {
        proxy_pass https://127.0.0.1:9200/; # and 8880 for wopi – mind that https in the case of ocis at the current state of this tutorial
        proxy_set_header Host $http_host;
        proxy_http_version 1.1;
        proxy_set_header X-Forwarded-Proto $scheme;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    }
</code></pre>

<p>Don&#39;t however forget to tell nginx how big your uploads can get, otherwise the webinterface may throw a confusing error.</p>

<h3 id="join-the-discussion">Join the discussion</h3>

<p>Discuss this topic on Mastodon:
<a href="https://social.tchncs.de/@milan/109853064593430899" rel="nofollow">https://social.tchncs.de/@milan/109853064593430899</a></p>

<hr>

<h3 id="update-log">Update log:</h3>
<ul><li>Feb 15: add frontend config</li>
<li>Feb 14: add email config</li></ul>

<p><a href="/milan/tag:owncloud" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">owncloud</span></a> <a href="/milan/tag:ocis" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">ocis</span></a> <a href="/milan/tag:onlyoffice" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">onlyoffice</span></a></p>

<p><strong>Signature (thanks for reading):</strong><br>
<a href="https://social.tchncs.de/@milan" rel="nofollow"><em>Follow me on Mastdodon</em></a></p>
]]></content:encoded>
      <guid>https://text.tchncs.de/milan/non-docker-owncloud-infinite-scale-with-onlyoffice</guid>
      <pubDate>Sun, 12 Feb 2023 17:14:26 +0000</pubDate>
    </item>
    <item>
      <title>About this Writefreely instance</title>
      <link>https://text.tchncs.de/milan/about-this-instance</link>
      <description>&lt;![CDATA[I am considering to replace our Plume with Writefreely in the future. However this time I&#39;ve decided to first do a test-deployment, before making it more official. Here are some notes about this setup:&#xA;&#xA;due to this temp domain and the unclear future, federation is disabled&#xA;due to the basic user management, a new authentication server replaces the internal login / signup form (it is a test installation as well)&#xA;&#xA;You can vote for or against this replacement here.&#xA;&#xA;What about Plume?&#xA;&#xA;Plume is – actually for a second time now - not under active development and its future is currently unclear (want to join its development? would be amazing!). It has a number of broken or even missing moderation features, making it very hard to keep the instance clean. &#xA;&#xA;Media uploads&#xA;&#xA;Writefreely does not support direct media uploads. Their commercial product uses an extra service for this purpose, which is expected to become opensource and available for 3rd party hosting (us) in the near future.&#xA;&#xA;Formatting&#xA;&#xA;Right now, you can use Markdown to format your blogs&#xA;&#xA;Blog visibility&#xA;&#xA;A blog is unlisted by default. You may alter its settings accordingly. This can be changed in the future if spam doesn&#39;t get out of hand. :)&#xA;&#xA;Note on logins&#xA;&#xA;The new authentication server formats usernames like [username]@[domain] -  user@tchncs.de. You may use this formatting when trying to login again.&#xA;&#xA;About the authentication server&#xA;&#xA;This new authentication server is supposed to help with other new or even old deployments of tchncs.de that have more basic account/signup security or moderation options. It might become an option for (in most cases new users) on existing tchncs.de services in the future. The server is powered by Zitadel and provides many cool features for your account.&#xA;&#xA;Writefreely is supposed to suggest username, displayname and email based on your account on this auth server, but this is currently broken. However that&#39;s mostly cosmetic. Under the hood a unique id is shared between these servers to identify your account.&#xA; &#xA;&#xA;Will this be deleted?&#xA;&#xA;If it proves useful over the next months, it will be moved to a new domain and your posts will survive. &#xA;&#xA;Signature (thanks for reading):  &#xD;&#xA;Follow me on Mastdodon]]&gt;</description>
      <content:encoded><![CDATA[<p>I am considering to replace our <a href="https://write.tchncs.de" rel="nofollow">Plume</a> with Writefreely in the future. However this time I&#39;ve decided to first do a test-deployment, before making it more official. Here are some notes about this setup:</p>
<ul><li>due to this temp domain and the unclear future, <strong>federation is disabled</strong></li>
<li>due to the basic user management, a <strong>new authentication server</strong> replaces the internal login / signup form (it is a test installation as well)</li></ul>

<p>You can vote for or against this replacement <a href="https://write.tchncs.de/~/Tchncsde/should-we-move-to-write-freely" rel="nofollow">here</a>.</p>

<h2 id="what-about-plume">What about Plume?</h2>

<p>Plume is – actually for a second time now – not under active development and its future is currently unclear (want to join its development? would be amazing!). It has a number of broken or even missing moderation features, making it very hard to keep the instance clean.</p>

<h2 id="media-uploads">Media uploads</h2>

<p>Writefreely does not support direct media uploads. Their commercial product uses an extra service for this purpose, which is expected to become opensource and available for 3rd party hosting (us) in the near future.</p>

<h2 id="formatting">Formatting</h2>

<p>Right now, you can use Markdown to format your blogs</p>

<h2 id="blog-visibility">Blog visibility</h2>

<p>A blog is unlisted by default. You may alter its settings accordingly. This can be changed in the future if spam doesn&#39;t get out of hand. :)</p>

<h2 id="note-on-logins">Note on logins</h2>

<p>The new authentication server formats usernames like <code>[username]@[domain] -&gt; user@tchncs.de</code>. You may use this formatting when trying to login again.</p>

<h2 id="about-the-authentication-server">About the authentication server</h2>

<p>This new authentication server is supposed to help with other new or even old deployments of tchncs.de that have more basic account/signup security or moderation options. It might become an option for (in most cases <em>new</em> users) on existing tchncs.de services in the future. The server is powered by Zitadel and provides <a href="https://zitadel.com/features" rel="nofollow">many cool features</a> for your account.</p>

<p>Writefreely is supposed to suggest <code>username</code>, <code>displayname</code> and <code>email</code> based on your account on this auth server, but <a href="https://discuss.write.as/t/generic-oauth-map-values-not-applied/7603" rel="nofollow">this is currently broken</a>. However that&#39;s mostly cosmetic. Under the hood a unique id is shared between these servers to identify your account.</p>

<h2 id="will-this-be-deleted">Will this be deleted?</h2>

<p>If it proves useful over the next months, it will be moved to a new domain and your posts will survive.</p>

<p><strong>Signature (thanks for reading):</strong><br>
<a href="https://social.tchncs.de/@milan" rel="nofollow"><em>Follow me on Mastdodon</em></a></p>
]]></content:encoded>
      <guid>https://text.tchncs.de/milan/about-this-instance</guid>
      <pubDate>Sun, 25 Dec 2022 11:07:42 +0000</pubDate>
    </item>
  </channel>
</rss>