0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

BitriseでAppStoreConnectAPI Basedのdeploy

Last updated at Posted at 2020-12-03

AppStoreConnectAPIの利用によって、Auto Provisioningの際に二段階認証とアプリ別シークレットを使うセッションベースの認証を使わなくてもよくなりました。

そちらの記事はいくつかあるのですが、Deploy to iTunes Storeの方の解説がなかったので、この記事に残します。

API BasedでAppStoreConnectにアップロードする方法

結論から言うと、「Deploy to iTunes Connect - Application Loader」ならAPI Basedでデプロイが可能です。ソースはこちら(公式)

手順

1. AppStoreConnectAPIとの連携

公式の手順があるのでこの記事では割愛します。
https://blog.bitrise.io/app-store-connect-api-on-bitrise

2. 「Deploy to iTunes Connect - Application Loader」を追加

以下のように、「Xcode Archive & Export」のステップでexport-methodが「app-store」のipa/pkgを吐き出した後の位置に「Deploy to iTunes Connect - Application Loader」ステップを挟みます。
スクリーンショット 2020-12-03 21.44.57.png

3. Configに「API Key URL」と「Issuer ID」を設定する

p8ファイルのURLとissuerIDを設定すれば良いのですが、前者に少し工夫が必要です。
スクリーンショット 2020-12-03 21.43.10.png

説明に書いてあるとおり、Workflow Editorタブの最下部にあるGeneric File Storageにp8ファイルをアップロードし、そのURLをAPI Key URLとして設定するようにしましょう。

↓この場所で、最初にFile Storage IDを入力し、その後にp8ファイルをドロップします。
スクリーンショット 2020-12-03 21.50.05.png

IssuerIDは環境変数(もしくはシークレット)として定義し利用すると良いでしょう。

まとめ

以上の設定で、AppStoreConnectにアプリケーションをデプロイできるはずです。

何か問題等あればコメントで教えてください。ありがとうございました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?