document how to clone 3rd party or old apps to use with standard container install and PHP 8.1

Ralf Becker 2022-10-27 10:02:46 +02:00
parent 7c44a1fba9
commit cb2bff0a30

@ -0,0 +1,64 @@
## Running own apps or the old depreacated ones in a standard Docker installation
> Our Docker containers only contains the default apps maintained by EGroupware GmbH.
Other third-party apps or the old deprecated ones like Wiki and KnowledgeBase can be integrated in the container, without the need of a developer installation or sacrificing the automatic update of the container / standard installation.
This article explains how this works and what you have to do.
The ```/etc/egroupware-docker/docker-compose.yml``` passes /usr/share/egroupware from the host into the container as /usr/share/egroupware-extra.
The container [entrypoint script](https://github.com/EGroupware/docker/blob/master/fpm/entrypoint.sh#L8) copies them into the volume shared between egroupware container and Nginx.
This mechanism can also be used to add arbitrary third-party apps to an EGroupware running in a container:
```
mkdir -p /usr/share/egroupware
cd /usr/share/egroupware
git clone <git-url>
docker restart egroupware # to run entry-point script and copy the app(s) into the container
```
### Old deprecated apps: Wiki, KnowledgeBase, ...
EGroupware 21.1 packages/containers come by default with PHP 7.4 and can still use the old 14.3 egroupware-epl-{wiki,knowledgebase,sitemgr} packages. You simply have to install them and you're done.
If you want to test EGroupware 21.1 with PHP 8.1 or run the next EGroupware version containing by default PHP 8.1, you can no longer use the above mentioned packages, as they lack the necessary PHP 8.1 fixes we made for Wiki, KnowledgeBase and the old (phpgw)API, required eg. for updating from old installations.
> SiteMgr, our old content-management-system, is no longer supported with PHP 8.1!
While EGroupware's next version packages will force the deinstallation of the old egroupware-epl-* packages, you can or even have to do that for testing with PHP 8.1 yourself for now:
```
apt|yum|zypper remove egroupware-epl-*
```
Then you manually have to clone the apps you want or need (no need to do that for all of them!):
* Wiki
```
mkdir -p /usr/share/egroupware
cd /usr/share/egroupware
git clone https://github.com/EGroupware/wiki.git
docker restart egroupware
```
* KnowledgeBase
```
mkdir -p /usr/share/egroupware
cd /usr/share/egroupware
for app in phpgwapi etemplate phpbrain; do
git clone https://github.com/EGroupware/$app.git
done
docker restart egroupware
```
* old (phpgw)API required for updating from before latest 14.3 (should be removed again after the update, if not using the KnowledgeBase!)
```
mkdir -p /usr/share/egroupware
cd /usr/share/egroupware
git clone https://github.com/EGroupware/phpgwapi.git
docker restart egroupware
```
> Using the cloned git repositories of the apps always has the benefit of contain the latest AND for PHP 8.1 necessary bug fixes.
To update / pull the latest bugfixes, step into the created directories and run ```git pull``` followed by ```docker restart egroupware```
```
cd /usr/share/egroupware
for git in */.git; do
(cd $(dirname $git); git pull)
done
docker restart egroupware
```