

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 對連線進行疑難排解
<a name="troubleshooting-connections"></a>

下列資訊可協助您針對 AWS CodeBuild AWS CodeDeploy、 和 中資源連線的常見問題進行疑難排解 AWS CodePipeline。

**Topics**
+ [我無法建立連線](#troubleshooting-connections-cannot-create)
+ [嘗試建立或完成連線時收到許可錯誤](#troubleshooting-connections-permissions-error-console)
+ [嘗試使用連線時收到許可錯誤](#troubleshooting-connections-permissions-error-useconnection)
+ [連線並非處於可用狀態或已脫離待定狀態](#troubleshooting-connections-error-notpending)
+ [新增 GitClone 的連線許可](#troubleshooting-connections-gitclone-permissions)
+ [主機並非處於可用狀態](#troubleshooting-connections-host-pending)
+ [針對發生連線錯誤的主機進行疑難排解](#troubleshooting-connections-host-errors)
+ [我無法為主機建立連線](#troubleshooting-connections-host-cannot-create)
+ [針對主機的 VPC 組態進行疑難排解](#troubleshooting-connections-host-vpc)
+ [針對 GitHub Enterprise Server 連線的 Webhook VPC 端點 (PrivateLink) 進行疑難排解](#troubleshooting-connections-host-vpc-webhook)
+ [針對 2020 年 11 月 24 日之前建立的主機進行疑難排解](#troubleshooting-connections-host-vpc-webhook-host)
+ [無法為 GitHub 儲存庫建立連線](#troubleshooting-connections-GitHub-admin)
+ [編輯 GitHub Enterprise Server 連線應用程式許可](#troubleshooting-GHES-app-permissions)
+ [連線至 GitHub 時發生連線錯誤：「發生問題，請確定您的瀏覽器已啟用 Cookie」或「組織擁有者必須安裝 GitHub 應用程式」](#troubleshooting-GitHub-organization-owner)
+ [資源中的連線服務字首可能需要更新 IAM 政策](#troubleshoot-service-prefix)
+ [使用主控台建立之資源中的服務字首導致許可錯誤](#troubleshoot-service-prefix-console-permissions)
+ [支援組織的已安裝供應商的連線和主機設定](#troubleshooting-organization-host)
+ [我想提高連線的限額](#troubleshooting-connections-limit-increase)

## 我無法建立連線
<a name="troubleshooting-connections-cannot-create"></a>

您可能沒有建立連線的許可。如需詳細資訊，請參閱[的許可和範例 AWS CodeConnections](security_iam_id-based-policy-examples-connections.md)。

## 嘗試建立或完成連線時收到許可錯誤
<a name="troubleshooting-connections-permissions-error-console"></a>

嘗試在 CodePipeline 主控台中建立或檢視連線時，可能會傳回下列錯誤訊息。

使用者：*使用者名稱*未獲授權在資源：*連線 ARN*上執行*許可*

如果顯示這則訊息，請確定您有足夠的許可。

在 AWS Command Line Interface (AWS CLI) 或 AWS 管理主控台 中建立和檢視連線的許可，只是您在主控台上建立和完成連線所需的許可的一部分。單純檢視、編輯或建立連線，然後完成待定連線所需的許可，範圍應該限制為只需要執行特定任務的使用者。如需詳細資訊，請參閱[的許可和範例 AWS CodeConnections](security_iam_id-based-policy-examples-connections.md)。

## 嘗試使用連線時收到許可錯誤
<a name="troubleshooting-connections-permissions-error-useconnection"></a>

如果您嘗試在 CodePipeline 主控台中使用連線，即使您具有列出、取得和建立許可，可能仍會傳回下列其中一個或兩個錯誤訊息。

無法驗證您的帳戶。

使用者：*使用者名稱*未獲授權在資源：*連線 ARN 上執行*：codestar-connections:UseConnection

如果出現此訊息，請確定您有足夠的許可。

請確定您擁有使用連線的許可，包括列出位於供應商位置的可用儲存庫。如需詳細資訊，請參閱[的許可和範例 AWS CodeConnections](security_iam_id-based-policy-examples-connections.md)。

## 連線並非處於可用狀態或已脫離待定狀態
<a name="troubleshooting-connections-error-notpending"></a>

如果主控台顯示連線並非處於可用狀態的訊息，請選擇 **Complete connection (完成連線)**。

如果您選擇完成連線，且出現連線不處於待定狀態的訊息，您可以取消請求，因為連線已處於可用狀態。

## 新增 GitClone 的連線許可
<a name="troubleshooting-connections-gitclone-permissions"></a>

當您在來源動作和 CodeBuild 動作中使用 AWS CodeStar 連線時，有兩種方式可以將輸入成品傳遞至組建：
+ 預設值：來源動作會產生 zip 檔，其中包含 CodeBuild 下載項目的程式碼。
+ Git 複製：來源程式碼可以直接下載到建置環境。

  Git 複製模式可讓您將原始程式碼當成工作中 Git 儲存庫來互動。若要使用此模式，您必須准許 CodeBuild 環境使用連線。

若要將許可新增至 CodeBuild 服務角色政策，請建立客戶受管政策以連接至 CodeBuild 服務角色。下列步驟建立政策，其中，`action` 欄位中指定 `UseConnection` 許可，而 `Resource` 欄位中指定連線的 Amazon Resource Name (ARN)。

**使用主控台新增 UseConnection 許可**

1. 若要尋找管道的連線 ARN，請開啟管道，然後選擇來源動作上的 (**i**) 圖示。「Configuration (組態)」窗格隨即會開啟，而連線 ARN 會顯示在 **ConnectionArn** 旁邊。您可以將連線 ARN 新增至 CodeBuild 服務角色政策。

1. 若要尋找 CodeBuild 服務角色，請開啟管道中使用的建置專案，然後瀏覽至 **Build details (建置詳細資訊)** 索引標籤。

1. 在「Environment (環境)」區段中，選擇 **Service role (服務角色)** 連結。這會開啟 AWS Identity and Access Management (IAM) 主控台，您可以在其中新增授予連線存取權的新政策。

1. 在 IAM 主控台，選擇 **Attach policies (連接政策)**，然後選擇 **Create policy (建立政策)**。

   使用下列政策範本範例。在 `Resource` 欄位中新增連線 ARN，如下列範例所示。

------
#### [ JSON ]

****  

   ```
   {
       "Version":"2012-10-17",		 	 	 
       "Statement": [
           {
               "Effect": "Allow",
               "Action": "codestar-connections:UseConnection",
               "Resource": "arn:aws:iam::*:role/Service*"
           }
       ]
   }
   ```

------

   在 **JSON** 索引標籤上，貼上您的政策。

1. 選擇**檢閱政策**。輸入政策的名稱 (例如 **connection-permissions**)，然後選擇 **Create policy (建立政策)**。

1. 返回服務角色的 **Attach Permissions (連接許可)** 頁面，重新整理政策清單，然後選取您剛建立的政策。選擇**連接政策**。

## 主機並非處於可用狀態
<a name="troubleshooting-connections-host-pending"></a>

如果主控台顯示訊息，指出主機並非處於 `Available` 狀態，請選擇 **Set up host (設定主機)**。

建立主機的第一個步驟會導致建立的主機現在處於 `Pending` 狀態。若要讓主機變為 `Available` 狀態，您必須選擇在主控台中設定主機。如需詳細資訊，請參閱[設定待定主機](connections-host-setup.md)。

**注意**  
您無法使用 AWS CLI 來設定`Pending`主機。

## 針對發生連線錯誤的主機進行疑難排解
<a name="troubleshooting-connections-host-errors"></a>

如果刪除或修改基礎 GitHub 應用程式，連線和主機可能會變為錯誤狀態。處於錯誤狀態的主機和連線無法復原，且必須重新建立主機。
+ 更改應用程式 pem 金鑰、更改應用程式名稱 (初始建立後) 等動作，會導致主機和所有相關聯的連線進入錯誤狀態。

如果主控台或 CLI 傳回處於 `Error` 狀態的主機或與主機相關的連線，您可能需要執行下列步驟：
+ 刪除並重新建立主機資源，然後重新安裝主機註冊應用程式。如需詳細資訊，請參閱[建立主機](connections-host-create.md)。

## 我無法為主機建立連線
<a name="troubleshooting-connections-host-cannot-create"></a>

 

若要建立連線或主機，必須符合以下條件。
+ 您的主機必須處於 **AVAILABLE (可用)** 狀態。如需詳細資訊，請參閱 
+ 必須在與主機相同的區域建立連線。

## 針對主機的 VPC 組態進行疑難排解
<a name="troubleshooting-connections-host-vpc"></a>

建立主機資源時，您必須提供安裝 GitHub Enterprise Server 執行個體的基礎設施之網路連線或 VPC 資訊。若要對主機的 VPC 或子網路組態進行疑難排解，請使用此處顯示的範例 VPC 資訊做為參考。

**注意**  
使用本節內容，對 Amazon VPC 內 GitHub Enterprise Server 主機組態相關問題進行疑難排解。如需針對設為使用 VPC 的 Webhook 端點 (PrivateLink) 之連線相關問題進行疑難排解，請參閱「[針對 GitHub Enterprise Server 連線的 Webhook VPC 端點 (PrivateLink) 進行疑難排解](#troubleshooting-connections-host-vpc-webhook)」。

在此範例中，您可以使用下列程序來設定 VPC 和伺服器 (GitHub Enterprise Server 執行個體的安裝位置)：

1. 建立 VPC。如需詳細資訊，請參閱[https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#Create-VPC](https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#Create-VPC)。

1. 在 VPC 中建立子網路。如需詳細資訊，請參閱[https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#AddaSubnet](https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#AddaSubnet)。

1. 將執行個體啟動至 VPC 中。如需詳細資訊，請參閱[https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#VPC_Launch_Instance](https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html#VPC_Launch_Instance)。

**注意**  
每個 VPC 一次只能與一個主機相關聯 (GitHub 企業伺服器執行個體) 相關聯。

下圖顯示使用 GitHub Enterprise AMI 啟動的 EC2 執行個體。

![\[主控台螢幕擷取畫面顯示執行個體描述\]](http://docs.aws.amazon.com/zh_tw/dtconsole/latest/userguide/images/instance-vpc.png)


使用 VPC 進行 GitHub Enterprise Server 連線時，您必須在設定主機時為基礎設施提供下列資訊：
+ **VPC ID：**安裝 GitHub Enterprise Server 執行個體的伺服器之 VPC，或可透過 VPN 或 Direct Connect 存取已安裝 GitHub Enterprise Server 執行個體的 VPC。
+ **子網路 ID 或 ID：**安裝 GitHub Enterprise Server 執行個體的伺服器之子網路，或可透過 VPN 或 Direct Connect 存取已安裝 GitHub Enterprise Server 執行個體的子網路。
+ **安全群組或群組：**安裝 GitHub Enterprise Server 執行個體的伺服器之安全群組，或可透過 VPN 或 Direct Connect 存取已安裝 GitHub Enterprise Server 執行個體的安全群組。
+ **端點：**準備好您的伺服器端點，繼續執行下一個步驟。

如需使用 VPC 和子網路的詳細資訊，請參閱 *Amazon VPC 使用者指南*中的 [IPv4 的 VPC 和子網路規模調整](https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html#vpc-sizing-ipv4)。

**Topics**
+ [我無法讓主機進入待定狀態](#troubleshooting-connections-host-vpc-failed)
+ [我無法讓主機進入可用狀態](#troubleshooting-connections-host-vpc-app)
+ [我的連線/主機本來正常運作，現在卻停止運作](#troubleshooting-connections-host-vpc-stopped)
+ [我無法刪除網路介面](#troubleshooting-connections-host-vpc-delete)

### 我無法讓主機進入待定狀態
<a name="troubleshooting-connections-host-vpc-failed"></a>

如果您的主機進入了 VPC\$1CONFIG\$1FAILED\$1INITIALIZATION 狀態，可能是因為您為主機選取的 VPC、子網路或安全群組出現問題。
+ VPC、子網路和安全群組都必須屬於建立主機的帳戶。
+ 子網路和安全群組必須屬於選取的 VPC。
+ 提供的每個子網路都必須位於不同的可用區域中。
+ 建立主機的使用者必須具有下列 IAM 權限：

  ```
  ec2:CreateNetworkInterface
  ec2:CreateTags
  ec2:DescribeDhcpOptionsec2:DescribeNetworkInterfaces
  ec2:DescribeSubnets
  ec2:DeleteNetworkInterface
  ec2:DescribeVpcs
  ec2:CreateVpcEndpoint
  ec2:DeleteVpcEndpoints
  ec2:DescribeVpcEndpoints
  ```

### 我無法讓主機進入可用狀態
<a name="troubleshooting-connections-host-vpc-app"></a>

如果您無法完成主機的 CodeConnections 應用程式設定，可能是因為 VPC 組態或 GitHub Enterprise Server 執行個體發生問題。
+ 如果您不是使用公有憑證授權機構，則需要為 GitHub Enterprise 執行個體所使用的主機提供 TLS 憑證。TLS 憑證值應該是憑證的公有金鑰。
+ 您需為 GitHub Enterprise Server 執行個體的管理員才能建立 GitHub 應用程式。

### 我的連線/主機本來正常運作，現在卻停止運作
<a name="troubleshooting-connections-host-vpc-stopped"></a>

如果連線/主機之前正常工作，現在卻無法正常運作，可能是因為 VPC 中的組態變更或 GitHub 應用程式經過修改。請檢查以下內容：
+ 連接至您為連線所建立主機資源的安全群組現在有所變更，或無法再存取 GitHub Enterprise Server。CodeConnections 需要可連線至 GitHub Enterprise Server 執行個體的安全群組。
+ DNS 伺服器 IP 最近有所變更。檢查連接至您為連線所建立主機資源中指定的 VPC 的 DHCP 選項，即可確認是否有變更。請注意，如果您最近從 AmazonProviedDNS 移轉至自訂 DNS 伺服器，或是開始使用新的自訂 DNS 伺服器，則主機/連線會停止運作。若要解決這個問題，請刪除您現有的主機並重新建立，這麼做會將最新的 DNS 設定存放在我的資料庫中。
+ 網路 ACL 設定已變更，不再允許 HTTP 連線到您的 GitHub Enterprise Server 基礎設施所在的子網路。
+ GitHub Enterprise Server 上 CodeConnections 應用程式的任何組態都已變更。修改任何組態，例如 URLs或應用程式秘密，可能會中斷已安裝的 GitHub Enterprise Server 執行個體與 CodeConnections 之間的連線。

### 我無法刪除網路介面
<a name="troubleshooting-connections-host-vpc-delete"></a>

如果您無法偵測到您的網路介面，請檢查下列項目：
+ CodeConnections 建立的網路界面只能透過刪除主機來刪除。使用者無法手動刪除這些網路介面。
+ 您必須具備下列許可：

  ```
  ec2:DescribeNetworkInterfaces
  ec2:DeleteNetworkInterface
  ```

## 針對 GitHub Enterprise Server 連線的 Webhook VPC 端點 (PrivateLink) 進行疑難排解
<a name="troubleshooting-connections-host-vpc-webhook"></a>

使用 VPC 組態建立主機時，系統會為您建立 Webhook VPC 端點。

**注意**  
使用本節內容，針對設為使用 VPC 的 Webhook 端點 (PrivateLink) 之連線相關問題進行疑難排解。如需對 Amazon VPC 內 GitHub Enterprise Server 主機組態相關問題進行疑難排解，請參閱「[針對主機的 VPC 組態進行疑難排解](#troubleshooting-connections-host-vpc)」。

當您建立與已安裝提供者類型的連線，且您已指定伺服器是在 VPC 內設定時， AWS CodeConnections 會建立您的主機，並為您建立 Webhook 的 VPC 端點 (PrivateLink)。這可讓主機透過 Webhook 透過 Amazon 網路將事件資料傳送至您的整合 AWS 服務。如需詳細資訊，請參閱[AWS CodeConnections 和介面 VPC 端點 (AWS PrivateLink)](vpc-interface-endpoints.md)。

**Topics**
+ [我無法刪除 Webhook VPC 端點](#troubleshooting-connections-host-vpc-webhook-delete)

### 我無法刪除 Webhook VPC 端點
<a name="troubleshooting-connections-host-vpc-webhook-delete"></a>

AWS CodeConnections 會管理主機的 Webhook VPC 端點生命週期。若要刪除端點，您必須刪除對應的主機資源。
+ CodeConnections 建立的 Webhook VPC 端點 (PrivateLink) 只能透過刪除主機來[刪除](https://docs.aws.amazon.com/dtconsole/latest/userguide/connections-host-delete.html)。這些端點無法手動刪除。
+ 您必須具備下列許可：

  ```
  ec2:DescribeNetworkInterfaces
  ec2:DeleteNetworkInterface
  ```

## 針對 2020 年 11 月 24 日之前建立的主機進行疑難排解
<a name="troubleshooting-connections-host-vpc-webhook-host"></a>

截至 2020 年 11 月 24 日， AWS CodeConnections 設定您的主機時，會為您設定額外的 VPC 端點 (PrivateLink) 支援。對於在此更新之前建立的主機，請使用本節疑難排解內容。

如需詳細資訊，請參閱[AWS CodeConnections 和介面 VPC 端點 (AWS PrivateLink)](vpc-interface-endpoints.md)。

**Topics**
+ [我有一個 2020 年 11 月 24 日之前建立的主機，而且想將 VPC 端點 (PrivateLink) 用於 Webhook](#troubleshooting-connections-host-vpc-webhook-create)
+ [我無法讓主機進入可用狀態 (VPC 錯誤)](#troubleshooting-connections-host-vpc-error-pre-webhook)

### 我有一個 2020 年 11 月 24 日之前建立的主機，而且想將 VPC 端點 (PrivateLink) 用於 Webhook
<a name="troubleshooting-connections-host-vpc-webhook-create"></a>

您為 GitHub Enterprise Server 設定主機時，系統會為您建立 Webhook 端點。連線現在使用 VPC PrivateLink Webhook 端點。如果您是在 2020 年 11 月 24 日之前建立主機，且想要使用 VPC PrivateLink Webhook 端點，您必須先[刪除](https://docs.aws.amazon.com/dtconsole/latest/userguide/connections-host-delete.html)主機，然後[建立](https://docs.aws.amazon.com/dtconsole/latest/userguide/connections-host-create.html)新主機。

### 我無法讓主機進入可用狀態 (VPC 錯誤)
<a name="troubleshooting-connections-host-vpc-error-pre-webhook"></a>

如果您的主機是在 2020 年 11 月 24 日之前建立的，而且您無法完成主機的 CodeConnections 應用程式設定，可能是因為 VPC 組態或 GitHub Enterprise Server 執行個體發生問題。

您的 VPC 需要一個 NAT 閘道 (或傳出網際網路存取權)，才能讓您的 GitHub Enterprise Server 執行個體傳送 GitHub Webhook 的輸出網路流量。

## 無法為 GitHub 儲存庫建立連線
<a name="troubleshooting-connections-GitHub-admin"></a>

**問題：**

由於 GitHub 儲存庫的連線使用 AWS Connector for GitHub，因此您需要儲存庫的組織擁有者許可或管理員許可，才能建立連線。

**可能的修正方式：**如需 GitHub 儲存庫許可層級的詳細資訊，請參閱 [https://docs.github.com/en/free-pro-team@latest/github/setting-up-and-managing-organizations-and-teams/permission-levels-for-an-organization](https://docs.github.com/en/free-pro-team@latest/github/setting-up-and-managing-organizations-and-teams/permission-levels-for-an-organization)。

## 編輯 GitHub Enterprise Server 連線應用程式許可
<a name="troubleshooting-GHES-app-permissions"></a>

如果您在 2020 年 12 月 23 日或之前安裝 GitHub Enterprise Server 的應用程式，您可能需要將應用程式的唯讀存取權提供給組織成員。如果您是 GitHub 應用程式擁有者，請依照下列步驟編輯建立主機時所安裝應用程式的許可。

**注意**  
您必須在 GitHub Enterprise Server 執行個體上完成這些步驟，而且您必須是 GitHub 應用程式擁有者。

1. 在 GitHub Enterprise Server 中，從您個人檔案照片上的下拉式選項中，選擇 **​Settings (設定)**。

1. 選擇 **Developer settings (開發人員設定)**，然後選擇 **GitHub Apps (GitHub 應用程式)**。

1. 在應用程式清單中，為連線選擇應用程式名稱，然後在設定畫面中選擇 **Permissions and events (許可與事件)**。

1. 在 **Organization permissions** (組織許可) 下，對於 **Members** (成員)，從 **Access** (存取權) 下拉式清單中選擇 **Read-only** (唯讀)。  
![\[Organization permissions interface showing Members access set to Read-only from dropdown menu.\]](http://docs.aws.amazon.com/zh_tw/dtconsole/latest/userguide/images/ghes-app-permissions.png)

1. 在 **Add a note to users (為使用者新增附註)** 底下，新增更新原因說明。選擇**儲存變更**。

## 連線至 GitHub 時發生連線錯誤：「發生問題，請確定您的瀏覽器已啟用 Cookie」或「組織擁有者必須安裝 GitHub 應用程式」
<a name="troubleshooting-GitHub-organization-owner"></a>

**問題：**

如要建立 GitHub 儲存庫的連線，您必須是 GitHub 組織擁有者。對於不在組織下的儲存庫，您必須是儲存庫擁有者。由組織擁有者以外的其他人員建立連線時，會針對組織擁有者建立請求，並顯示下列其中一個錯誤：

發生問題，請確保您的瀏覽器已啟用 cookie

或

組織擁有者必須安裝 GitHub 應用程式

**可能修正：**對於 GitHub 組織中的儲存庫，組織擁有者必須建立與 GitHub 儲存庫的連線。對於不在組織下的儲存庫，您必須是儲存庫擁有者。

## 資源中的連線服務字首可能需要更新 IAM 政策
<a name="troubleshoot-service-prefix"></a>

服務已於 2024 年 3 月 29 日從 AWS CodeStar Connections 重新命名為 AWS CodeConnections。從 2024 年 7 月 1 日開始，主控台會在資源 ARN `codeconnections`中建立與 的連線。具有兩個服務字首的資源將繼續顯示在主控台中。使用主控台建立之資源的服務字首為 `codeconnections`。在資源 ARN `codeconnections`中使用 建立新的 SDK/CLI 資源。建立的資源會自動具有新的服務字首。

以下是在 AWS CodeConnections 中建立的資源：
+ 連線
+ 主機

**問題：**

在 ARN `codestar-connections`中使用 建立的資源不會自動重新命名為資源 ARN 中的新服務字首。建立新資源會建立具有連線服務字首的資源。不過，具有`codestar-connections`服務字首的 IAM 政策不適用於具有新服務字首的資源。

**可能的修正：**為了避免資源的存取或許可問題，請完成下列動作：
+ 更新新服務字首的 IAM 政策。否則，重新命名或建立的資源將無法使用 IAM 政策。
+ 使用主控台或 CLI/CDK/CFN 建立新服務字首，以更新資源。

視需要更新政策中的動作、資源和條件。在下列範例中，這兩個服務字首的 `Resource` 欄位已更新。

------
#### [ JSON ]

****  

```
{
    "Version":"2012-10-17",		 	 	 
    "Statement": {
        "Effect": "Allow",
        "Action": [
            "codeconnections:UseConnection"
        ],
        "Resource": [
            "arn:aws:codestar-connections:*:*:connection/*",
            "arn:aws:codeconnections:*:*:connection/*"
        ]
    }
}
```

------

## 使用主控台建立之資源中的服務字首導致許可錯誤
<a name="troubleshoot-service-prefix-console-permissions"></a>

目前，使用主控台建立的連線資源只會有 `codestar-connections`服務字首。對於使用主控台建立的資源，政策陳述式動作必須包含 `codestar-connections`做為服務字首。

**注意**  
從 2024 年 7 月 1 日開始，主控台會在資源 ARN `codeconnections`中建立與 的連線。具有兩個服務字首的資源將繼續顯示在主控台中。

**問題：**

使用 主控台建立連線資源時，必須在政策中使用 `codestar-connections`服務字首。在政策中使用具有`codeconnections`服務字首的政策時，使用主控台建立的連線資源會收到下列錯誤訊息：

```
User: user_ARN is not authorized to perform: codestar-connections:action on resource: resource_ARN because no identity-based policy allows the codestar-connections:action action
```

**可能的修正：**對於使用主控台建立的資源，政策陳述式動作必須包含 `codestar-connections`做為服務字首，如 中的政策範例所示[範例： AWS CodeConnections 使用主控台建立 的政策](security_iam_id-based-policy-examples-connections.md#security_iam_id-based-policy-examples-connections-console)。

## 支援組織的已安裝供應商的連線和主機設定
<a name="troubleshooting-organization-host"></a>

對於支援組織，例如 GitHub Organizations 的已安裝供應商，您不會傳遞可用的主機。您可以為組織中的每個連線建立新的主機，並務必在下列網路欄位中輸入相同的資訊：
+ **VPC ID**
+ **子網路 ID**
+ **安全群組 IDs**

請參閱建立 [GHES 連線](https://docs.aws.amazon.com/dtconsole/latest/userguide/connections-create-gheserver.html)或 [GitLab 自我管理連線](https://docs.aws.amazon.com/dtconsole/latest/userguide/connections-create-gitlab-managed.html)的相關步驟。

## 我想提高連線的限額
<a name="troubleshooting-connections-limit-increase"></a>

您可以在 CodeConnections 中請求提高特定限制的限制。如需詳細資訊，請參閱[連線的配額](limits-connections.md)。