IBM / aspera-cli

IBM Aspera CLI
Apache License 2.0
77 stars 17 forks source link

Feature Request - aoc options for files subcommand #165

Closed ngenchi closed 3 weeks ago

ngenchi commented 3 weeks ago

Hey Aspera team,

I am trying to create a new folder (ascli aoc files mkdir) in a workspace that originates in ats-aws-us-west-2.aspera.io but the Files Shared Folder resides in ats-aws-eu-west-2.aspera.io. Whenever I make ascli command using JWT tokens as a non-admin user the mkdir command fails. If I run the same command as an ATS Admin it is successful.

Any chance there is a way to add the variable of sending the command to a different node?

I tried opening a case with IBM but they were not able to assist.

Thanks, Nick

laurent-martin commented 3 weeks ago

Can you specify the version you use ? (there was a fix for that a couple of versions ago). Also, let's depict the precise scenario, like

ngenchi commented 3 weeks ago

Currently using ascli v 4.19.0, workspace in aoc; user auth is rsa key - jwt token, all files shared folders are created by admin then shared to users.

Based on the debug logs I see when running the command, it calls https://api.ibmaspera.com/api/v1/workspaces/_**SERVER A ID**_ which then tries to connect to the original node (server A) where the shared folder doesn't exist.

When running the same command as an ATS admin it will retry the command and eventually find the correct ATS server B and create the folder.

laurent-martin commented 3 weeks ago

Ok, I have reproduced:

$ ascli aoc files mkdir /on-eudemo/test1
Workspace: Marketing Laurent
ERROR: Rest: File_type='link' for file_id='73144' not supported
code: 415
reason: Unsupported Media Type
files-prod-es-dal13.asperafiles.com 415 Unsupported Media Type

Fix should come soon and in next version. I'll let know here when a beta is available.

laurent-martin commented 3 weeks ago

Download beta here install with: gem install aspera-cli-4.20.0.pre.gem