nextcloud / nextcloud/HaRP

Harp Proxy Fails to Start in Proxmox 9 LXC due to Restricted Syscalls

Open
#50 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
54
Forks
10
Avg merge
40m
Merged PRs (30d)
3

Description

Hi everybody,

I'm running Nextcloud in a a privileged LXC on Proxmox 9/Debian 13 and am running into issues deploying the HaRp Proxy.

When I run this command:

docker run \
  -e HP_SHARED_KEY="password" \
  -e NC_INSTANCE_URL="http://domain.org" \
  -e HP_EXAPPS_ADDRESS="127.0.0.1:8780" \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -v "$(pwd)"/certs:/certs \
  --name appapi-harp \
  -h appapi-harp \
  --restart unless-stopped \
  --network host \
  -d ghcr.io/nextcloud/nextcloud-appapi-harp:release

the container won't start up:

AttributeError: '_UnixSelectorEventLoop' object has no attribute '_ssock'
sys:1: RuntimeWarning: coroutine 'main' was never awaited

Full log here

I already tried adding this to the configuration of my Nextcloud-LXC:

lxc.apparmor.profile: unconfined
features: nesting=1
lxc.cgroup2.devices.allow: a
lxc.cgroup.devices.allow: a
raw.lxc: |
  lxc.seccomp = 0

but that didn't help either.

When I add --security-opt apparmor=unconfined \ to the docker run command, the Harp container starts up without problems. However, then the deployment test from the Nextcloud configuration fails.

ChatGPT tells me: LXC on Proxmox 9 (Debian 13) still restricts certain kernel syscalls (e.g. socketpair()) even in a privileged container with AppArmor and Seccomp disabled. This blocks Python’s asyncio event loop and HAProxy’s CLI socket creation.

Is it possible that HaRP is not compatible with Debian 13 or generally incompatible with LXCs?

Thanks!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the supplied Docker command in a privileged Proxmox 9/Debian 13 LXC and inspect the linked startup log, focusing on the asyncio event-loop and restricted-syscall errors. Compare behavior with and without the AppArmor security option, then run the Nextcloud deployment test. Done means establishing supported LXC behavior or documenting the required compatibility change and verifying deployment succeeds without the workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
debian, docker, python
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.