Uploading multiple files simultaneously to a support ticket through REST (curl) fails in Linux

プラットフォームについて: Data Center のみ。 - This article only applies to Atlassian apps on the Data Center プラットフォーム

この KB は Data Center バージョンの製品用に作成されています。Data Center 固有ではない機能の Data Center KB は、製品のサーバー バージョンでも動作する可能性はありますが、テストは行われていません。 Server* 製品のサポートは 2024 年 2 月 15 日に終了しました。Server 製品を実行している場合は、 アトラシアン Server サポート終了 のお知らせにアクセスして、移行オプションを確認してください。

*Fisheye および Crucible は除く

要約

There are situations where multiple files are needed to be uploaded to a support ticket, and doing it through the support portal can take a lot of time. The link https://transfer.atlassian.com/auth_token offers a solution for it, but the command provided fails in Linux.

環境

Running the command line in a Linux machine.

診断

When attempting to execute the command offered in the link mentioned previously, the error shown is:

$ curl -u NTU3MDU4OjM5MGZkMzEyLWY0OTUtNDgyZi04MmFkLThhZDZlMjRiZjljMA==:<token> -X POST \ --header "Transfer-Encoding: chunked" \ -F "files[]=@/var/atlassian/application-data/bitbucket/export/Bitbucket.zip" \ -F "files[]=@/var/atlassian/application-data/bitbucket/export/thread_dumps.zip" \ https://transfer.atlassian.com/api/upload/ABC-12345 $ curl: (26) Failed to open/read local data from file/application

原因

Even though the command is correct, Linux can't process double quotation marks as the example shows.

ソリューション

Change the double quotation marks for single quotation marks:

$ curl -u NTU3MDU4OjM5MGZkMzEyLWY0OTUtNDgyZi04MmFkLThhZDZlMjRiZjljMA==:<token> -X POST \ --header "Transfer-Encoding: chunked" \ -F 'files[]=@/var/atlassian/application-data/bitbucket/export/Bitbucket.zip' \ -F 'files[]=@/var/atlassian/application-data/bitbucket/export/thread_dumps.zip' \ https://transfer.atlassian.com/api/upload/ABC-12345

更新日時: September 26, 2025

さらにヘルプが必要ですか?

アトラシアン コミュニティをご利用ください。