Skip to content

Feature/team member installations - #283

Merged
vsilent merged 3 commits into
devfrom
feature/team-member-installations
Oct 14, 2026
Merged

vsilent merged 3 commits into
devfrom
feature/team-member-installations

Conversation

@vsilent

@vsilent vsilent commented Oct 14, 2026

Copy link
Copy Markdown
Collaborator

This pull request introduces a new feature allowing project owners to control whether project members receive server SSH keys and passwords in deployment reports. It adds a new database field and API endpoints to manage this setting, updates the deployment flow to notify the correct user(s), and improves access control and reporting for deployments initiated by project members. Additionally, it introduces a new endpoint for determining a user's role in a deployment and updates authorization rules accordingly.

Project Member Server Access Feature:

  • Added a new members_server_access boolean column to the project table, with database migrations to support toggling whether project members receive servers' SSH keys and passwords in deployment reports. Includes new functions in db::project to read and update this setting. [1] [2] [3]
  • Implemented a new PATCH API endpoint /project/:id/server-access allowing project owners to enable or disable server access for members, with the corresponding handler and form. [1] [2]
  • Updated the project invitation API (seats endpoint and response struct) to include the current value of members_server_access for transparency to clients. [1] [2] [3]

Deployment Reporting and Initiator Tracking:

  • Introduced logic to track and propagate the "initiator" (the member who triggered the deployment) so that deployment reports can be sent to both the owner and the member when appropriate. This includes adding an initiator_email field to deployment forms and payloads, updating the deployment flow to set this field, and ensuring it is only set by the server. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14]

Deployment Access and Authorization:

  • Added a new endpoint /api/v1/deployments/:deployment_hash/member-access to determine a user's role (owner, member, viewer) for a deployment, intended for use by internal services. Updated Casbin authorization rules to allow anonymous group GET access to this endpoint, and included corresponding up/down migrations. [1] [2] [3] [4]

Internal Improvements and Refactoring:

  • Refactored and exposed the require_stacker_service_auth function for internal service authentication.

These changes collectively improve security, transparency, and flexibility in how deployment reports are handled for project members, and provide supporting APIs for internal and external consumers.

robotizeit and others added 3 commits October 14, 2026 18:13
GET /api/v1/deployments/{hash}/member-access?user_id=... answers
owner/member/viewer/null for the deployment's project, so the User Service
can let a Team project member operate the owner's installation (agent
install, add-app, redeploy). Service token only, like the other
service-to-service routes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012TKZy6f5shPzM9WLdswH6f
A project member deploys as the owner, so the install payload carried only
the owner's address and the member who started the deployment never got
the report. The payload now carries initiator_email for deploy, deploy with
a saved cloud and rollback by a member. It is set by the server only:
Payload is read from client-supplied project metadata, so the field is
never deserialized.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012TKZy6f5shPzM9WLdswH6f
The deployment report carries the server's SSH key and passwords. A member
who deploys now gets it only when the owner turned on server access for
members: project.members_server_access, off by default, set through
PATCH /project/{id}/server-access (owner only) and shown in /seats.
Without it the report goes to the owner only, as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012TKZy6f5shPzM9WLdswH6f
@vsilent
vsilent merged commit 964442d into dev Oct 14, 2026
9 of 10 checks passed
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.

2 participants