Rootless docker : Slim Application Error

I’m trying to install nextcloud-aio on a raspberry pi as a rootless docker image. I’ve tried to follow your readme and have read lots of discussions with the same error message, but can’t solve the problem.

I’ve tried different docker-ruin commands, the last being

docker run --sig-proxy=false --name nextcloud-aio-mastercontainer --restart always --publish 8077:80 --publish 8088:8080 --publish 8448:8443 --publish 8443:443 --volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config --volume /run/user/1001/docker.sock:/var/run/docker.sock:ro nextcloud/all-in-one:latest

Did I miss anything in your documentation?

Opening the setup always yields an exception:

Details

Type: GuzzleHttp\Exception\ServerException

Code: 500

Message: Server error: POST http://localhost/v1.41/containers/nextcloud-aio-domaincheck/start resulted in a 500 Internal Server Error response: {ā€œmessageā€:"driver failed programming external connectivity on endpoint nextcloud-aio-domaincheck (fed3d052dfe0559d31fd7 (truncated…)

File: /var/www/docker-aio/php/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php

Line: 113

Trace

#0 /var/www/docker-aio/php/vendor/guzzlehttp/guzzle/src/Middleware.php(72): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Psr7\Request), Object(GuzzleHttp\Psr7\Response), NULL, Array, NULL) #1 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(209): GuzzleHttp\Middleware::GuzzleHttp{closure}(Object(GuzzleHttp\Psr7\Response)) #2 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(158): GuzzleHttp\Promise\Promise::callHandler(1, Object(GuzzleHttp\Psr7\Response), NULL) #3 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/TaskQueue.php(52): GuzzleHttp\Promise\Promise::GuzzleHttp\Promise{closure}() #4 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(251): GuzzleHttp\Promise\TaskQueue->run(true) #5 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(227): GuzzleHttp\Promise\Promise->invokeWaitFn() #6 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(272): GuzzleHttp\Promise\Promise->waitIfPending() #7 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(229): GuzzleHttp\Promise\Promise->invokeWaitList() #8 /var/www/docker-aio/php/vendor/guzzlehttp/promises/src/Promise.php(69): GuzzleHttp\Promise\Promise->waitIfPending() #9 /var/www/docker-aio/php/vendor/guzzlehttp/guzzle/src/Client.php(189): GuzzleHttp\Promise\Promise->wait() #10 /var/www/docker-aio/php/vendor/guzzlehttp/guzzle/src/ClientTrait.php(95): GuzzleHttp\Client->request(ā€˜POST’, ā€˜http://localhos…’, Array) #11 /var/www/docker-aio/php/src/Docker/DockerActionManager.php(182): GuzzleHttp\Client->post(ā€˜http://localhos…’) #12 /var/www/docker-aio/php/src/Controller/DockerController.php(48): AIO\Docker\DockerActionManager->StartContainer(Object(AIO\Container\Container)) #13 /var/www/docker-aio/php/src/Controller/DockerController.php(257): AIO\Controller\DockerController->PerformRecursiveContainerStart(ā€˜nextcloud-aio-d…’) #14 /var/www/docker-aio/php/public/index.php(81): AIO\Controller\DockerController->StartDomaincheckContainer() #15 /var/www/docker-aio/php/vendor/slim/slim/Slim/Handlers/Strategies/RequestResponse.php(38): Closure->{closure}(Object(GuzzleHttp\Psr7\ServerRequest), Object(GuzzleHttp\Psr7\Response), Array) #16 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/Route.php(358): Slim\Handlers\Strategies\RequestResponse->__invoke(Object(Closure), Object(GuzzleHttp\Psr7\ServerRequest), Object(GuzzleHttp\Psr7\Response), Array) #17 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\Routing\Route->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #18 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\MiddlewareDispatcher->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #19 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/Route.php(315): Slim\MiddlewareDispatcher->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #20 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/RouteRunner.php(68): Slim\Routing\Route->run(Object(GuzzleHttp\Psr7\ServerRequest)) #21 /var/www/docker-aio/php/vendor/slim/csrf/src/Guard.php(476): Slim\Routing\RouteRunner->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #22 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(168): Slim\Csrf\Guard->process(Object(GuzzleHttp\Psr7\ServerRequest), Object(Slim\Routing\RouteRunner)) #23 /var/www/docker-aio/php/vendor/slim/twig-view/src/TwigMiddleware.php(115): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #24 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Views\TwigMiddleware->process(Object(GuzzleHttp\Psr7\ServerRequest), Object(Psr\Http\Server\RequestHandlerInterface@anonymous)) #25 /var/www/docker-aio/php/src/Middleware/AuthMiddleware.php(38): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #26 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(269): AIO\Middleware\AuthMiddleware->__invoke(Object(GuzzleHttp\Psr7\ServerRequest), Object(Psr\Http\Server\RequestHandlerInterface@anonymous)) #27 /var/www/docker-aio/php/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(76): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #28 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\ErrorMiddleware->process(Object(GuzzleHttp\Psr7\ServerRequest), Object(Psr\Http\Server\RequestHandlerInterface@anonymous)) #29 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #30 /var/www/docker-aio/php/vendor/slim/slim/Slim/App.php(199): Slim\MiddlewareDispatcher->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #31 /var/www/docker-aio/php/vendor/slim/slim/Slim/App.php(183): Slim\App->handle(Object(GuzzleHttp\Psr7\ServerRequest)) #32 /var/www/docker-aio/php/public/index.php(181): Slim\App->run() #33 {main}

Yes, APACHE_PORT and AIO interface cannot use the same port.

thanks for the quick response. Sorry for not reading carefully enough. I’ve tried again with

docker run --env APACHE_PORT=8444 --sig-proxy=false --name nextcloud-aio-mastercontainer --restart always --publish 8077:80 --publish 8088:8080 --publish 8443:8443 --publish 8444:8444 --volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config --volume /run/user/1001/docker.sock:/var/run/docker.sock:ro nextcloud/all-in-one:latest

but with the same exception. Is there anything special about rootless docker, which has to be configured (on Raspberry PI)
?

You have made the same mistake again.

Actually you can just remove --publish 8444:8444 and --publish 8077:80 from the command as that is not needed in case you want to run AIO behind a reverse proxy. Do you want to actually run AIO behind a reverse proxy because port 443 is already used or is that not what you are intending to do?

Is it posible that some remnants of previous attempts are still active in some ā€œhiddenā€ memories? I’ve removed docker containers, docker images and browser histories, but I’m always sent directly to the login page. The password appeared only the very first time, so it must be somewhere stored now?

Indeed it is after the first installation stored in the nextcloud_aio_mastercontainer volume. As long as you do not delete this volume, it will keep the data.

I’m trying in a first attempt to provide nextcloud only within my home network on an Raspberry Pi server, which is running nginx for my home network. But I didn’t want to use this nginx instance but to run nextcloud stand-alone with it’s own webserver in a docker-environment. Did I completely misunderstand the docs for this puspose? Maybe I’ve to return to studying the docs again?

I see. Then you probably tried to follow all-in-one/local-instance.md at main Ā· nextcloud/all-in-one Ā· GitHub in combination with all-in-one/docker-rootless.md at main Ā· nextcloud/all-in-one Ā· GitHub?

yes, the Raspi is headless and I had to look for the correct location of docker.sock etc. but that at least works.

I see. you have a very complicated setup there. Fortunately I am nice today and will describe some steps more in detail:

First, I hope you already followed steps 0-5 of this documentation? all-in-one/docker-rootless.md at main Ā· nextcloud/all-in-one Ā· GitHub

Afterwards should the following command work and should allow you to log in via port 8080:

docker run \
--sig-proxy=false \
--name nextcloud-aio-mastercontainer \
--restart always \
--publish 8080:8080 \
--volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \
--volume /run/user/1001/docker.sock:/var/run/docker.sock:ro \
-e WATCHTOWER_DOCKER_SOCKET_PATH=/run/user/1001/docker.sock \
-e APACHE_PORT=11000 \
-e APACHE_IP_BINDING=0.0.0.0 \
nextcloud/all-in-one:latest

Next follow one of these guides: all-in-one/local-instance.md at main Ā· nextcloud/all-in-one Ā· GitHub (but you can leave out the creation of the mastercontainer since that is already done. Only the other parts need to be set up in that case).

Thanks a lot. I’m now able to login. I think, the docker rootless inst was correct, I did all the steps at the beginnig. So your docker-run-command was the solution.
Thanks for the great support.