Cannot properly setup AppApi daemon for exApps

The Basics

  • Nextcloud Server version (e.g., 29.x.x):

    • 33.0.3
  • Operating system and version (e.g., Ubuntu 24.04):

    • Debian GNU/Linux 12 (bookworm) (Yunohost 12.1.39) / Linux 6.1.0-48-amd64 x86_64
  • Web server and version (e.g, Apache 2.4.25):

    • nginx/1.22.1

    Reverse proxy and version _(e.g. nginx 1.27.2)

    • nginx/1.22.1
  • PHP version (e.g, 8.3):

    • 8.4.21
  • Is this the first time you’ve seen this error? (Yes / No):

    • Yes
  • When did this problem seem to first start?

    • When trying to setup AppAPI and External Apps
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)

    • Bare Metal (Yunohost)
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)

    • No

Summary of the issue I am facing:

I cannot properly setup AppApi :confused:

I have followed the steps described in the documentation (via both methods, first setting HaRP then Docker Socket Proxy docker containers).

I am able to get the Daemon properly connected but never manage to test the whole setup with “Test deploy” :confused: which seems to fail even before starting.

In the NC logs I get the following error message (this one is for Docker Socker Proxy method but I get the similar error for HaRP) :

Log entries

Nextcloud

[app_api] Erreur: Error executing occ command. Return code: 1, stdout: An unhandled exception has been thrown:
Doctrine\DBAL\Exception: Failed to connect to the database: An exception occurred in the driver: could not find driver in /var/www/nextcloud/lib/private/DB/Connection.php:238
Stack trace:
#0 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(458): OC\DB\Connection->connect()
#1 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(416): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /var/www/nextcloud/3rdparty/doctrine/dbal/src/Connection.php(323): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /var/www/nextcloud/lib/private/DB/Connection.php(922): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /var/www/nextcloud/lib/private/DB/ConnectionAdapter.php(243): OC\DB\Connection->getDatabaseProvider()
#5 /var/www/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php(97): OC\DB\ConnectionAdapter->getDatabaseProvider()
#6 /var/www/nextcloud/lib/private/AppConfig.php(1353): OC\DB\QueryBuilder\QueryBuilder->expr()
#7 /var/www/nextcloud/lib/private/AppConfig.php(284): OC\AppConfig->loadConfig()
#8 /var/www/nextcloud/lib/private/AppConfig.php(1833): OC\AppConfig->searchValues()
#9 /var/www/nextcloud/lib/private/Memcache/Factory.php(122): OC\AppConfig->getAppInstalledVersions()
#10 /var/www/nextcloud/lib/private/Memcache/Factory.php(163): OC\Memcache\Factory->getGlobalPrefix()
#11 /var/www/nextcloud/lib/private/Server.php(937): OC\Memcache\Factory->createLocking()
#12 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(186): OC\Server->OC\{closure}()
#13 /var/www/nextcloud/3rdparty/pimple/pimple/src/Pimple/Container.php(122): OC\AppFramework\Utility\SimpleContainer->OC\AppFramework\Utility\{closure}()
#14 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(149): Pimple\Container->offsetGet()
#15 /var/www/nextcloud/lib/private/ServerContainer.php(155): OC\AppFramework\Utility\SimpleContainer->query()
#16 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(46): OC\ServerContainer->query()
#17 /var/www/nextcloud/lib/private/Files/View.php(82): OC\AppFramework\Utility\SimpleContainer->get()
#18 /var/www/nextcloud/lib/private/Server.php(425): OC\Files\View->__construct()
#19 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(186): OC\Server->OC\{closure}()
#20 /var/www/nextcloud/3rdparty/pimple/pimple/src/Pimple/Container.php(122): OC\AppFramework\Utility\SimpleContainer->OC\AppFramework\Utility\{closure}()
#21 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(149): Pimple\Container->offsetGet()
#22 /var/www/nextcloud/lib/private/ServerContainer.php(155): OC\AppFramework\Utility\SimpleContainer->query()
#23 /var/www/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php(46): OC\ServerContainer->query()
#24 /var/www/nextcloud/lib/private/Server.php(1286): OC\AppFramework\Utility\SimpleContainer->get()
#25 /var/www/nextcloud/lib/base.php(699): OC\Server->boot()
#26 /var/www/nextcloud/lib/base.php(1288): OC::init()
#27 /var/www/nextcloud/console.php(32): require_once('...')
#28 {main}, stderr: 
	POST /apps/app_api/daemons/docker_socket_proxy/test_deploy
	de 37.167.20.30 par guitch à 18 mai 2026, 20:39:56

Configuration

Nextcloud

{
    "system": {
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "partage.***REMOVED SENSITIVE VALUE***"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "33.0.3.2",
        "overwrite.cli.url": "https:\/\/partage.okko.io\/",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "ldapIgnoreNamingRules": false,
        "ldapProviderFactory": "OCA\\User_LDAP\\LDAPProviderFactory",
        "updatechecker": false,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "integrity.check.disabled": true,
        "filelocking.enabled": true,
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": "6379",
            "timeout": "0.0",
            "password": "***REMOVED SENSITIVE VALUE***"
        },
        "logout_url": "https:\/\/okko.io\/yunohost\/sso\/?action=logout&r=aHR0cHM6Ly9wYXJ0YWdlLm9ra28uaW8v",
        "maintenance": false,
        "mysql.utf8mb4": true,
        "default_phone_region": "",
        "loglevel": 2,
        "hashing_default_password": true,
        "mail_smtpmode": "smtp",
        "mail_sendmailmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "25",
        "mail_smtpsecure": "tls",
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpauth": 1,
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "app_install_overwrite": [
            "passman",
            "documentserver_community",
            "cms_pico",
            "news",
            "podcast",
            "maps"
        ],
        "localstorage.allowsymlinks": true,
        "simpleSignUpLink.shown": false,
        "theme": "",
        "memories.exiftool": "\/var\/www\/nextcloud\/apps\/memories\/bin-ext\/exiftool-amd64-glibc",
        "memories.vod.path": "\/var\/www\/nextcloud\/apps\/memories\/bin-ext\/go-vod-amd64",
        "memories.vod.ffmpeg": "\/usr\/bin\/ffmpeg",
        "memories.vod.ffprobe": "\/usr\/bin\/ffprobe",
        "preview_max_x": 2048,
        "preview_max_y": 2048,
        "memories.vod.disable": false,
        "data-fingerprint": "2cee8f9671b1834b8686636f00fa5970",
        "enabledPreviewProviders": [
            "OC\\Preview\\Image",
            "OC\\Preview\\TIFF",
            "OC\\Preview\\Movie"
        ],
        "mail_smtpstreamoptions": {
            "ssl": {
                "allow_self_signed": true,
                "verify_peer": false,
                "verify_peer_name": false
            }
        },
        "logfile": "\/var\/log\/nextcloud\/nextcloud.log",
        "maintenance_window_start": 1,
        "memories.gis_type": 1,
        "memories.db.triggers.fcu": true,
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "trashbin_retention_obligation": "auto, 30",
        "versions_retention_obligation": "auto, 30",
        "lost_password_link": "disabled"
    }
}

Thank you very much for your help !

Guitch

[adding english translation]

Haven’t totally figured out the Flow 1.3.1 installation but slowly progressing :slight_smile:

The error I have reported in this ticket is due to the use of the wrong php version : /usr/bin/php was pointing to php8.2 instead of php8.4 → changed the symbolic link to have php point to php8.4 fix the issue…

… but I was still not able to install properly Flow 1.3.1.

To finally achieve the proper installation, I have followed this tutorial Tutorial: Install 1.2.0 (newer version is broken) · Issue #132 · nextcloud/flow · GitHub to first install Flow 1.2.0 then right after it, upgraded it to 1.3.1.

Solved !

Hope this may help anyone encountering same problem I did…

Guitch


[ici la version française]

Je n’ai pas encore réussi à installer Flow (1.3.1) sur mon NC (33.0.3) mais je progresse (doucement).

L’erreur reportée dans ce ticket provient du fait que php pointe vers php8.2 au lieu de php8.4 ce qui empêche la commande occ de se lancer correctement au démarrage de l’installation de flow.

Remplacer la version par défaut de php (changer le lien symbolique /usr/bin/php pour pointer vers /usr/bin/php8.4 fonctionne !

Maintenant l’image docker de flow se télécharge et le container se charge (via le dameon AppApi !)… mais d’autres erreur se produisent :

Le log du daemon de déploiement renvoie :

[2026-06-09T17:36:09+0000] [ERROR] Certificate update command failed in container 'nc_app_flow'. Exit: 137, Raw Output: +Updating certificates in /etc/ssl/certs...

[2026-06-09T17:36:09+0000] [ERROR] Failed to create FRP cert dir '/certs/frp' in container 'nc_app_flow'. Exit: 128, Raw Output: FailedPrecondition: container 1dc78b72df5a842743db1b1be07ca88ba4ee2ffe19535c622cc3b84b95211c49 init process is not running: failed precondition

[2026-06-09T17:36:09+0000] [ERROR] Error during certificate installation for 'nc_app_flow': Internal Server Error

Pour résoudre ce blocage, j’ai d’abord installé la version 1.2.0 en suivant ce tuto : https://github.com/nextcloud/flow/issues/132 puis immédiatement mis à jour à la version 1.3.1

Résolu !

En espérant que ça puisse éventuellement aider certain·es qui auraient rencontré les mêmes difficultés…

Guitch