Open NShaforostov opened 4 years ago
I've tried to verify this. In common, it works well. Some issues, that were encountered:
pipe share get <RUN_ID>
prints the error with a traceback, where RUN_ID
is the run ID:
pipe share add <RUN_ID>
without additional options prints the error with a traceback:
Is it possible to print only short error message in such cases?pipe share add <RUN_ID> -su/sg <USER>/<GROUP>
without specifying -ssh
option (for the run without endpoints) prints the error with a traceback:
Is it possible to print only short error message in such cases?pipe share remove <RUN_ID>
without additional options prints the error, nothing happens:
But without any options this command shall clear all list of the shared users/groups.pipe share remove -ssh <RUN_ID>
without additional options prints the error, nothing happens:
But this command shall remove only SSH-sharing for all users/groups for runs with endpoint(s) or remove all users/groups of the run shared list for runs without endpoints.
Background For certain use cases, it is beneficial to be able to share applications with other users/groups. Currently, Cloud Pipeline supports the ability to access runs environments for several users, not only for the user, who launched the run (OWNER). On the GUI, it's implemented via the "Sharing" feature that allows to share runs as the interactive tools endpoints and SSH sessions for several users/groups. It would be convenient to allow users to share runs via the
pipe
CLI.Approach
pipe share <sub-command> <Run_ID>
, that shall manage the sharing of the specified runpipe share get <Run_ID>
- to display a list of users/groups for whom the run is shared Example of the output:pipe share add <Run_ID> [OPTIONS]
- to add user(s)/group(s) to a list for whom the run is sharedpipe share remove <Run_ID> [OPTIONS]
- to remove user(s)/group(s) from a list for whom the run is shared-su
|--shared-user <user>
. In case of several users, they could be specified each with that flag (-su USER1 -su USER2 ...
)-sg
|--shared-group <group>
. In case of several groups, they could be specified each with that flag (-sg GROUP1 -sg GROUP2 ...
)-su
or-sg
) shall be specified for theadd
sub-commandremove
sub-command without any options shall clear all list of the shared users/groups-ssh
|--share-ssh
command examples:
This command shall be available only for admin or the run OWNER.