Hello everyone,
I am currently trying to expose my Nextcloud Docker instance to a domain using Cloudflare Tunnel. The domain is properly configured, and the tunnel seems to be set up correctly. However, I am encountering a fatal error when accessing Nextcloud:
Fatal error: Uncaught Error: Class âOCP\Serverâ not found in /var/www/html/index.php:81
Stack trace:
#0 {main} thrown in /var/www/html/index.php on line 81.
Here is the configuration I have set up in config.php
:
<?php
$CONFIG = array (
'htaccess.RewriteBase' => '/',
'memcache.local' => '\\OC\\Memcache\\APCu',
'apps_paths' =>
array (
0 =>
array (
'path' => '/var/www/html/apps',
'url' => '/apps',
'writable' => false,
),
1 =>
array (
'path' => '/var/www/html/custom_apps',
'url' => '/custom_apps',
'writable' => true,
),
),
'upgrade.disable-web' => true,
'instanceid' => 'YOUR_INSTANCE_ID',
'passwordsalt' => 'YOUR_PASSWORD_SALT',
'secret' => 'YOUR_SECRET',
'trusted_domains' =>
array (
0 => 'localhost',
1 => 'YOUR_DOMAIN',
),
'datadirectory' => '/var/www/html/data',
'dbtype' => 'pgsql',
'version' => '30.0.2.2',
'dbname' => 'nextcloud',
'dbhost' => 'YOUR_DB_HOST',
'dbport' => '',
'dbtableprefix' => 'oc_',
'dbuser' => 'YOUR_DB_USER',
'dbpassword' => 'YOUR_DB_PASSWORD',
'installed' => true,
'memories.exiftool' => '/var/www/html/custom_apps/memories/bin-ext/exiftool-amd64-glibc',
'memories.vod.path' => '/var/www/html/custom_apps/memories/bin-ext/go-vod-amd64',
'maintenance' => false,
'overwrite.cli.url' => 'https://YOUR_DOMAIN',
);
System Details:
-
Operating System (Manjaro Linux)
- Kernel:
6.9.12-3-MANJARO
- Type: Rolling release based on Arch Linux.
- Architecture:
x86_64
- Preemptive Kernel:
SMP PREEMPT_DYNAMIC
- Kernel:
-
PHP
- Version: PHP
8.3.14
- Zend Engine:
v4.3.14
- Non-Thread Safe (NTS)
- Version: PHP
-
Docker
- Version:
27.3.1
- Build:
ce1223035a
- Version:
I have verified the Docker container logs and ensured that everything seems fine with the container setup. The Nextcloud instance runs smoothly locally but throws this error when accessed via the tunnel.
Has anyone encountered this issue before or have suggestions on how to resolve it? Any help would be appreciated!