Skip to content

Add user-slice plumbing for ascend/asctl#30

Draft
cryi with Copilot wants to merge 6 commits into
mainfrom
copilot/add-user-slices-support
Draft

Add user-slice plumbing for ascend/asctl#30
cryi with Copilot wants to merge 6 commits into
mainfrom
copilot/add-user-slices-support

Conversation

Copilot AI commented Apr 22, 2026

Copy link
Copy Markdown

This adds the basic plumbing for per-user ascend instances, similar to systemctl --user. ascend now resolves into a user slice automatically when started as a non-root Unix user, and asctl can target user slices explicitly.

  • User-slice resolution

    • Added shared slice resolution logic in src/common/slices.lua
    • Non-root Unix ascend defaults now move from system paths to per-user paths:
      • services under XDG_CONFIG_HOME / ~/.config
      • logs under XDG_STATE_HOME / ~/.local/state
      • IPC socket under XDG_RUNTIME_DIR when available
    • System-scope defaults remain unchanged for root/system operation
  • CLI targeting

    • Added --user / -u support to asctl
    • asctl --user targets the current user slice
    • asctl --user=<name> targets another user’s slice via a user-specific socket path
  • Process model changes

    • When ascend is running in user-slice mode, per-service user overrides are ignored
    • This keeps the process model aligned with a user-owned slice instead of mixing per-service identity changes
  • Docs and coverage

    • Updated the README to document user-slice behavior and asctl --user
    • Added focused isolation tests for:
      • user-slice default path/socket resolution
      • explicit cross-user asctl socket targeting
      • ignoring service-level user overrides in user-slice mode

Example:

# current user's ascend instance
asctl --user list

# another user's ascend instance
asctl --user=alice status my-service

Copilot AI linked an issue Apr 22, 2026 that may be closed by this pull request
Copilot AI and others added 5 commits April 22, 2026 06:23
Agent-Logs-Url: https://github.com/alis-is/ascend/sessions/2d159042-87eb-47b0-bd27-3941f8b19082

Co-authored-by: cryi <36897290+cryi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/alis-is/ascend/sessions/2d159042-87eb-47b0-bd27-3941f8b19082

Co-authored-by: cryi <36897290+cryi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/alis-is/ascend/sessions/2d159042-87eb-47b0-bd27-3941f8b19082

Co-authored-by: cryi <36897290+cryi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/alis-is/ascend/sessions/2d159042-87eb-47b0-bd27-3941f8b19082

Co-authored-by: cryi <36897290+cryi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/alis-is/ascend/sessions/2d159042-87eb-47b0-bd27-3941f8b19082

Co-authored-by: cryi <36897290+cryi@users.noreply.github.com>
Copilot AI changed the title [WIP] Add support for user slices management Add user-slice plumbing for ascend/asctl Apr 22, 2026
Copilot finished work on behalf of cryi April 22, 2026 06:28
Copilot AI requested a review from cryi April 22, 2026 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

user slices

2 participants