Nextcloud All-In-One fails to update, watchtover segfaults?
Author: lvetsCreated Mar 9, 2024Updated Nov 17, 2025
LabelsType: BugPriority: MediumStatus: Available
Describe the bug
I've installed Nextcloud AIO on a docker rootless setup. I'm trying to update the mastercontainer by stopping all containers and then clicking "Update mastercontainer". This shows "Mastercontainer update currently running. It will restart the mastercontainer soon which will make it unavailable for a moment. Please wait until that's done. (Logs)" for a couple of seconds then goes back to the main AIO screen. Nothing seems to happen...
Apparently, the actual update is done by a watchtower container. When I check the logs of that container, I see the following:
time="2024-03-03T22:07:00Z" level=debug msg="Sleeping for a second to ensure the docker api client has been properly initialized."
time="2024-03-03T22:07:01Z" level=debug msg="Making sure everything is sane before starting"
time="2024-03-03T22:07:01Z" level=info msg="Watchtower 1.7.1"
time="2024-03-03T22:07:01Z" level=info msg="Using no notifications"
time="2024-03-03T22:07:01Z" level=info msg="Only checking containers which name matches \"nextcloud-aio-mastercontainer\""
time="2024-03-03T22:07:01Z" level=info msg="Running a one time update."
time="2024-03-03T22:07:01Z" level=debug msg="Checking containers for updated images"
time="2024-03-03T22:07:01Z" level=debug msg="Retrieving running containers"
time="2024-03-03T22:07:01Z" level=error msg="Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?"
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x30 pc=0x9fa4e2]
goroutine 1 [running]:
github.com/containrrr/watchtower/pkg/metrics.NewMetric({0x0, 0x0})
/home/runner/work/watchtower/watchtower/pkg/metrics/metrics.go:31 +0x22
github.com/containrrr/watchtower/cmd.runUpdatesWithNotifications(0xc00031f490)
/home/runner/work/watchtower/watchtower/cmd/root.go:377 +0x171
github.com/containrrr/watchtower/cmd.Run(0xc00031a300?, {0xc000332080?, 0x4?, 0x4?})
/home/runner/work/watchtower/watchtower/cmd/root.go:168 +0x658
github.com/spf13/cobra.(*Command).execute(0xc00031a300, {0xc000138010, 0x4, 0x4})
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:987 +0xaa7
github.com/spf13/cobra.(*Command).ExecuteC(0xc00031a300)
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1115 +0x417
github.com/spf13/cobra.(*Command).Execute(...)
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1039
github.com/containrrr/watchtower/cmd.Execute()
/home/runner/work/watchtower/watchtower/cmd/root.go:75 +0x52
main.main()
/home/runner/work/watchtower/watchtower/main.go:13 +0x17Steps to reproduce
See above.
Expected behavior
Nextcloud All-In-One updates successfully and everything is hunky-dory.
Screenshots
No response
Environment
- Platform: Ubuntu 22.04 LTS.
- Architecture: x86-64
- Docker Version: 25.0.3.
Your logs
time="2024-03-03T22:07:00Z" level=debug msg="Sleeping for a second to ensure the docker api client has been properly initialized."
time="2024-03-03T22:07:01Z" level=debug msg="Making sure everything is sane before starting"
time="2024-03-03T22:07:01Z" level=info msg="Watchtower 1.7.1"
time="2024-03-03T22:07:01Z" level=info msg="Using no notifications"
time="2024-03-03T22:07:01Z" level=info msg="Only checking containers which name matches \"nextcloud-aio-mastercontainer\""
time="2024-03-03T22:07:01Z" level=info msg="Running a one time update."
time="2024-03-03T22:07:01Z" level=debug msg="Checking containers for updated images"
time="2024-03-03T22:07:01Z" level=debug msg="Retrieving running containers"
time="2024-03-03T22:07:01Z" level=error msg="Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?"
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x30 pc=0x9fa4e2]
goroutine 1 [running]:
github.com/containrrr/watchtower/pkg/metrics.NewMetric({0x0, 0x0})
/home/runner/work/watchtower/watchtower/pkg/metrics/metrics.go:31 +0x22
github.com/containrrr/watchtower/cmd.runUpdatesWithNotifications(0xc00031f490)
/home/runner/work/watchtower/watchtower/cmd/root.go:377 +0x171
github.com/containrrr/watchtower/cmd.Run(0xc00031a300?, {0xc000332080?, 0x4?, 0x4?})
/home/runner/work/watchtower/watchtower/cmd/root.go:168 +0x658
github.com/spf13/cobra.(*Command).execute(0xc00031a300, {0xc000138010, 0x4, 0x4})
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:987 +0xaa7
github.com/spf13/cobra.(*Command).ExecuteC(0xc00031a300)
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1115 +0x417
github.com/spf13/cobra.(*Command).Execute(...)
/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1039
github.com/containrrr/watchtower/cmd.Execute()
/home/runner/work/watchtower/watchtower/cmd/root.go:75 +0x52
main.main()
/home/runner/work/watchtower/watchtower/main.go:13 +0x17Additional context
No response
Source: containrrr/watchtower