Enterprise Server 用の GitHub アプリを手動で作成する

If you’re using GitHub Enterprise Server (version 2.18 or lower), the instructions on this page will help you manually create an app to connect your GitHub account with Jira.

If you're using GitHub Enterprise Server on version 2.19 or higher, you can create an app automatically when you connect Jira with GitHub.

GitHub で新しいアプリを作成する

Once you’ve installed the GitHub for Atlassian app and selected a server to connect, Jira will prompt you to create an app in GitHub.

  1. Jira で [アプリの手動作成] を選択します。

  2. Open the GitHub Enterprise website in a new tab and log in to your Enterprise Server account.

  3. 開発者設定 (http(s)://<your-domain>/settings/apps) に移動します。

  4. Select GitHub Apps and then New GitHub App.

  5. アプリに固有の名前を付けて、必要に応じて説明を追加します。

  6. http(s)://<your-domain>/apps/<your-github-app-name という形式でドメインとアプリ名を組み合わせてホームページ URL を作成します。

Jira から GitHub に URL をコピーする

次に、Jira の手動アプリ作成ページの URL を GitHub にコピーします。

  1. [User Authorization Callback URL (ユーザー認証コールバック URL)] をコピーして、GitHub の [Callback URL (コールバック URL)] フィールドに貼り付けます。

  2. [Setup URL (セットアップ URL)] をコピーして GitHub のフィールドに貼り付けます。

  3. [Webhook URL] をコピーして GitHub のフィールドに貼り付けます。

  4. Webhook の秘密のフレーズを作成します。

    1. GitHub ではこれは必須ではありませんが、Jira が Webhook イベントをリッスンして処理するには必須です。「jirarocks」のようにランダムなものでもかまいません。

GitHub で権限を付与する

Jira で Webhook イベントをリッスンし、GitHub の開発データを入力できるようにするには、権限とイベント サブスクリプションを追加する必要があります。

  1. Add the following repository permissions:

    1. アクション (読み取り専用)

    2. コンテンツ (読み取り & 書き込み)

    3. デプロイ (読み取り専用)

    4. Work items (read & write)

    5. メタデータ (読み取り専用、必須)

    6. プル リクエスト (読み取り & 書き込み)

  2. Add the following organizational permission:

    1. メンバー (読み取り専用)

  3. Select the following event subscriptions:

    1. セキュリティ勧告

    2. コミット コメント

    3. 作成

    4. 削除

    5. デプロイのステータス

    6. Work item comment

    7. Work items

    8. Pull request

    9. プル リクエストのレビュー

    10. プッシュ

    11. リポジトリ

    12. ワークフローの実行

「読み取り & 書き込み」権限は必須ではありませんが、この権限がないと「ブランチの作成」機能が動作しません。

GitHub でアプリの詳細を送信する

  1. GitHub アプリ フォームのすべてのフィールドを確認します。

  2. [Create GitHub App (GitHub App を作成)] を選択し、アプリを保存して送信します。

アプリの詳細を GitHub から Jira にコピーする

最後に、アプリの詳細を GitHub から Jira の手動アプリ作成ページにコピーします。

  1. [App ID (アプリ ID)] フィールドと [Client ID (クライアント ID)] フィールドをコピーして、Jira の対応する各フィールドに貼り付けます。

  2. [Generate a new client secret (新しいクライアント シークレットを生成)] を選択して、ページが更新されるのを待ってから、そのシークレットをコピーして Jira の [GitHub client secret (GitHub クライアント シークレット)] フィールドに貼り付けます。

  3. [Generate a private key (非公開キーを生成)] を選択して PEM ファイルをダウンロードします。このファイルを Jira の [非公開キー] フィールドにアップロードします。

  4. [GitHub app name (GitHub アプリの名前)] フィールドと [Webhook secret (Webhook シークレット)] フィールドが GitHub と Jira で一致していることを確認します。

    1. Webhook シークレットを GitHub で確認するには、[Edit (編集)] を選択します。

 

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

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