# Setting Up Google GCR

## 1. Move to the external registry creation screen

1\) Navigate to \[Build Configuration] - \[External Container Registries].

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FQb4KHSkhfLJLQEdZvZ1b%2Fimage.png?alt=media&#x26;token=5d87e9cd-89f0-485d-b21e-5b9a41bb1bd2" alt=""><figcaption><p>[Screen] Registries</p></figcaption></figure>

2\) Click the "+ Register" button in the upper right corner to select the provider for creation.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FhtixHfpsauQ4Ah4QxLhX%2Fimage.png?alt=media&#x26;token=70a57061-cf7f-4991-85d8-ba7ba9bc79c3" alt=""><figcaption><p>[Screen] Select External Registries</p></figcaption></figure>

## 2. Enter Registry Registration Information

1\) Click the "+ Register" button and select "Google GCR."

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FGFHbBQ2I2ONJhR5DFDhA%2Fimage.png?alt=media&#x26;token=92d974a4-99a4-4031-93a3-467db320993e" alt=""><figcaption><p>[Screen] Select External Registries(Google GCR)</p></figcaption></figure>

2\) After registering Google GCR  authentication information in the basic information, click the "Test Connection" button.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FZzLayIMWXQYD9X1VG742%2Fimage.png?alt=media&#x26;token=564e52f9-3145-4bf6-9f24-dc4bc59293c3" alt=""><figcaption><p>[Screen] Register  Google GCR Registry Authentication Information</p></figcaption></figure>

| Item (\* is required) | Content                                                            |
| --------------------- | ------------------------------------------------------------------ |
| Name\*                | Enter the name of the external container registry to be registered |
| Describe              | Enter a description for the external container registry            |
| Endpoint URL\*        | Enter the Endpoint URL corresponding to the registry region        |
| Registry\*            | Enter the name of the already registered registry                  |
| Access ID\*           | \_json\_key                                                        |
| Access JSON\*         | Enter the google service account private key (in JSON key format)  |

* List of regions: <https://cloud.google.com/artifact-registry/docs/repositories/repo-locations>

1. Enter the name for the registry to be created in the registry.
2. Enter a description for the registry in the description.
3. Enter the EndPoint URL in the correct format.
4. Enter the registry name.
5. Enter Access ID and Access JSON.
6. Click "Test Connection" in the upper right corner to verify if the registry is available.
7. Click the "Save" button in the upper right corner.

***

### **Access JSON Verification Steps**

1\) Log in to the Google Cloud Console.

{% embed url="<https://cloud.google.com/cloud-console>" %}

2\) In the Google Cloud Console, click on the "IAM & Admin" button.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FlyBfTGgpu1uu0k3GqZ1d%2Fimage.png?alt=media&#x26;token=1d80b0b4-9435-4ca7-b38c-ed2ec034ba20" alt=""><figcaption></figcaption></figure>

3\) Under the "IAM & Admin" tab, click on "Service Accounts," then click the "+ Create Service Account" button at the top center.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2F6vx3ZKIDxpu9kMkZaG2o%2Fimage.png?alt=media&#x26;token=c7633080-c96f-46c2-97be-d9d54696c8cf" alt=""><figcaption></figcaption></figure>

4\) Set the name for the service account. then click "CREATE AND CONTINUE"button.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2Fp9myn50TguFGl5Vwabcb%2Fimage.png?alt=media&#x26;token=abcd005f-7af5-46f6-8ef3-2f95bff5de9c" alt=""><figcaption></figcaption></figure>

5\) Set the permissions for the service account to be created.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FXbYSLJqYyhhvq0v8oDLo%2Fimage.png?alt=media&#x26;token=2d3b8011-eed8-49cd-b41f-d272862a3111" alt=""><figcaption></figcaption></figure>

**Owner permissions grant full access to most Google Cloud resources.**

**You can provide different permissions if needed, but access may be restricted based on the assigned permissions..**

6\) Click on the created service account, click "Add Key," then click "Create a new key," choose JSON format, and click "Create."

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FOEUwaBAnos9k54ntlNMO%2Fimage.png?alt=media&#x26;token=3224c1bf-0bd9-453f-83f7-7ad8205fd6bb" alt=""><figcaption></figcaption></figure>

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FEdiWp7rXz4wKdcgTLqCs%2Fimage.png?alt=media&#x26;token=e91830d5-3bd2-4a56-abc0-628f2f9ac542" alt=""><figcaption></figcaption></figure>

7\) Verify that the JSON file has been generated locally.

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FoSqQRi0nH4QnC2ZgL24q%2Fimage.png?alt=media&#x26;token=0d079ad3-7bd4-4330-adfa-8e59c0cccd7f" alt=""><figcaption></figcaption></figure>

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2F4fZXmIAsn14iDVl3CnLQ%2Fimage.png?alt=media&#x26;token=fc11b7b3-153c-4bad-b87f-cdffcbf28997" alt=""><figcaption></figcaption></figure>

`Accss JSON` : File contents

### **Project ID Verification**

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2FjIrDS6a8sA8X7CuReREA%2Fimage.png?alt=media&#x26;token=82c4e4a6-2136-4eb7-a8f2-88b3331cfaaf" alt=""><figcaption></figcaption></figure>

`Project ID` : The name in the leftmost select box in the search.

### **Registry & Endpoint URL Verification**

<figure><img src="https://4196990571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL5As9l8R3RbLkQd6XsfL%2Fuploads%2Fd0M3chyx1G3QILvvTkUF%2Fimage.png?alt=media&#x26;token=6341e8fa-4098-4e7a-b8aa-4c2ac054f564" alt=""><figcaption></figcaption></figure>

`레지스트리` : Repository name

`Endpoint URL` : Region of the registry to be created
