Skip to content

btcpayserver: joins clightning's user name instead of its group for the RPC socket #86

Closed

Description

@ostermayer

Problem

modules/btcpayserver.nix line 271 adds the btcpayserver user to cfg.clightning.user when the lightning backend is clightning:

++ optional (cfg.btcpayserver.lightningBackend == "clightning") cfg.clightning.user;

The intent is membership in clightning's group, which owns the lightning-rpc socket (rpc-file-mode=0660). It works today only because services.clightning.group defaults to cfg.user (modules/clightning.nix line 82). An operator who sets a different services.clightning.group gets a btcpayserver that can't open the socket, with no error at evaluation time.

Fix

Use cfg.clightning.group on that line. One word. I can send the PR.

How found

LLM review (Kimi K3 max, GLM 5.3 max) flagged this. I verified it against the code. Severity: low, correctness.

Activity

  1. added
    area: modules
    good first issue
    type: bug
    on Oct 23, 2026
  2. added a commit that references this issue on Nov 10, 2026
    f46eb86
  3. added a commit that references this issue on Nov 10, 2026
    12567c3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: modulesgood first issuetype: bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions