Service Account Setup

Creating a Service Account for DuploCloud GCP and adding a private key

A service account and a key are created for each GCP project to be onboarded.

Disable Restriction on the Service Account Key

  1. Login to the GCP Console and select the desired project from the GCP Project list box.

  2. In the left navigation pane, in IAM and admin, select Organization Policies.

  3. Filter and search for iam.disableServiceAccountKeyCreation.

  4. Add a Rule (Rule 1 in the graphic below) to turn off enablement.

Creating a Service Account

  1. In the left navigation pane, click IAM and Admin -> Service Accounts.

  2. In the Grant this service account access to project step, assign the Owner role as shown below, giving the account owner permission to the project.

  1. Select the Service Account and create a new Key of type JSON.

  2. Download the JSON file and give it a meaningful name, such as my-gcp-project-sa-key.json.

  3. Open a Terminal window and navigate to the location of the downloaded file.

  4. Run the following command. This copies the Key contents to your clipboard. You can verify the contents by pasting it into a text editor.

jq -r .private_key < my-gcp-project-sa-key.json| pbcopy

Adding the Service Account Private Key to the DuploCloud Portal

To add the private key to DuploCloud:

  1. Login to the DuploCloud and navigate to Administrator -> Cloud Credentials. The Cloud Credentials page displays.

  2. Paste the key in the Service Account Private Key field.

  3. Enter a Display name for easy reference, preferably including the project name.

  4. Enter the Project ID and Service Account Email from the JSON key file you downloaded.

  5. Click Submit.

Last updated

Logo

© DuploCloud, Inc. All rights reserved. DuploCloud trademarks used herein are registered trademarks of DuploCloud and affiliates