Skip to content

Conversation

@J4Wx
Copy link
Contributor

@J4Wx J4Wx commented Mar 24, 2025

The worker create action currently allows you to select any SSH user across the server: https://github.com/vitodeploy/vito/blob/2.x/app/Web/Pages/Servers/Workers/Actions/Create.php#L27

But the worker edit action only allows you to choose "vito" or "root".
https://github.com/vitodeploy/vito/blob/2.x/app/Web/Pages/Servers/Workers/Widgets/WorkersList.php#L150

This results in a broken looking form whenever editing a worker, and needing to delete and recreate a worker if you need to change to a user that isn't "root" or "vito".

@saeedvaziry
Copy link
Member

How about this?

->options(
                   $site ? 
                       array_combine($site->getSshUsers(), $site->getSshUsers()) : 
                       array_combine($server->getSshUsers(), $server->getSshUsers())
                ),

for Edit and Create worker

@saeedvaziry saeedvaziry merged commit f350049 into vitodeploy:2.x Apr 5, 2025
3 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