Skip to content

added helper scripts to get started#851

Closed
edennuriel wants to merge 1 commit intoGoogleCloudPlatform:mainfrom
edennuriel:learn
Closed

added helper scripts to get started#851
edennuriel wants to merge 1 commit intoGoogleCloudPlatform:mainfrom
edennuriel:learn

Conversation

@edennuriel
Copy link

setup dependencies and create your host projects

setup dependencies and create your host projects
@edennuriel edennuriel closed this Mar 2, 2026
@google-cla
Copy link

google-cla bot commented Mar 2, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request significantly enhances the developer onboarding experience by introducing a suite of helper scripts designed to streamline both local development environment setup and Google Cloud Platform project provisioning. It automates the installation of critical tools and the creation of foundational GCP infrastructure across development, UAT, and production stages, ensuring consistency and reducing manual configuration effort.

Highlights

  • Development Environment Setup Script: Introduced a comprehensive setup_dev_env.sh script that automates the installation and configuration of essential development tools like Git, Make, jq, Python 3, unzip, Terraform, GitHub CLI, uv, and Google Cloud SDK. It includes special handling for Nix/IDX environments to ensure declarative dependency management.
  • GCP Project Provisioning Script: Added a create_project.sh script that leverages Terraform to provision Google Cloud Platform projects. This script guides the user through validating input, checking for existing projects, retrieving billing and organization details, and applying Terraform configurations to create 'dev', 'uat', and 'prod' environments.
  • Terraform Configuration for GCP Projects: Provided Terraform (main.tf, variables.tf) to define the infrastructure for three distinct GCP environments (dev, uat, prod). This includes creating Google Cloud projects, enabling necessary APIs (Compute, Service Management, Resource Manager, Billing, IAM), and setting up default VPC networks and subnets with private IP access.
  • Automated Google Cloud SDK Configuration: Integrated gcloud authentication and project configuration into the setup scripts, ensuring that the user's Google Cloud environment is correctly set up and that project IDs are persisted, including optionally updating the .idx/dev.nix file for IDX users.
Changelog
  • .idx/dev.nix
    • Added a new Nix configuration file to define the development environment's dependencies, including various packages like jq, uv, gh, terraform, google-cloud-sdk, go, python311, and nodejs_20.
    • Configured the PROJECT_ID environment variable within the Nix environment.
  • setup/create_project.sh
    • Added a new bash script to automate the creation of GCP projects.
    • Implemented input validation for the project base name.
    • Included logic to check for and warn about existing GCP projects.
    • Automated the retrieval of GCP billing account and organization IDs.
    • Integrated Terraform execution for project creation, planning, and application.
    • Added functionality to extract created project IDs and update a local .env file.
  • setup/project/main.tf
    • Added a new Terraform configuration file to define GCP infrastructure.
    • Defined local variables for environments (dev, uat, prod) and required APIs.
    • Configured the creation of unique Google Cloud projects for each environment using random_id.
    • Enabled a set of essential Google Cloud APIs for each created project.
    • Provisioned default VPC networks with auto-create subnets disabled for each project.
    • Created default subnets within the VPCs, specifying IP CIDR ranges and enabling private IP Google access.
    • Defined outputs for the dev, uat, and prod project IDs.
  • setup/project/terraform.tfstate
    • Added a new Terraform state file, capturing the state of the managed GCP infrastructure.
  • setup/project/terraform.tfstate.backup
    • Added a new Terraform state backup file, storing a previous state of the managed GCP infrastructure.
  • setup/project/variables.tf
    • Added a new Terraform variables file to define input parameters for the GCP project creation.
    • Declared variables for project_base_name, billing_account, org_id, and region with descriptions and a default value for region.
  • setup/setup_dev_env.sh
    • Added a new bash script to check for and install development dependencies.
    • Implemented helper functions for colored output (info, warn, success, error, prompt).
    • Included specific logic to configure Nix/IDX environments by checking and adding missing packages to .idx/dev.nix.
    • Provided standard installation routines for non-IDX environments, supporting macOS (Homebrew) and Linux (apt, dnf, yum).
    • Automated the installation of Git, Make, jq, Python 3, unzip, Terraform, GitHub CLI, uv, and Google Cloud SDK.
    • Configured gcloud authentication, default project, and Application Default Credentials (ADC) quota project.
    • Added aliases for terraform (tf) and less (more).
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@edennuriel edennuriel deleted the learn branch March 2, 2026 04:05
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a set of helper scripts and Terraform configurations to automate the setup of development environments and the creation of GCP projects for dev, uat, and prod. The changes are a good step towards simplifying the onboarding process.

My review includes several important points:

  • Critical: Terraform state files have been included in the commit. These should be removed and added to .gitignore to prevent security risks and collaboration issues.
  • High: The Terraform configuration uses the same network CIDR for all environments, which will cause IP conflicts. This should be parameterized.
  • Medium: A few improvements to the shell scripts to fix ineffective aliases and avoid configuration issues in IDX environments.

Overall, the scripts are well-structured, but the issues with Terraform state and networking need to be addressed before merging.

Comment on lines +1 to +717
{
"version": 4,
"terraform_version": "1.8.3",
"serial": 34,
"lineage": "950f8d90-63ba-0bf3-1779-e06198f422b8",
"outputs": {
"dev_project_id": {
"value": "edn-asp-dev-d999ec05",
"type": "string"
},
"prod_project_id": {
"value": "edn-asp-prod-625d6cfe",
"type": "string"
},
"uat_project_id": {
"value": "edn-asp-uat-c4ef6fcc",
"type": "string"
}
},
"resources": [
{
"mode": "managed",
"type": "google_compute_network",
"name": "vpc",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"auto_create_subnetworks": false,
"bgp_always_compare_med": false,
"bgp_best_path_selection_mode": "LEGACY",
"bgp_inter_region_cost": "",
"delete_bgp_always_compare_med": false,
"delete_default_routes_on_create": false,
"description": "",
"enable_ula_internal_ipv6": false,
"gateway_ipv4": "",
"id": "projects/edn-asp-dev-d999ec05/global/networks/default",
"internal_ipv6_range": "",
"mtu": 0,
"name": "default",
"network_firewall_policy_enforcement_order": "AFTER_CLASSIC_FIREWALL",
"network_id": "6722168448933764172",
"network_profile": "",
"numeric_id": "6722168448933764172",
"params": [],
"project": "edn-asp-dev-d999ec05",
"routing_mode": "REGIONAL",
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/global/networks/default",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"auto_create_subnetworks": false,
"bgp_always_compare_med": false,
"bgp_best_path_selection_mode": "LEGACY",
"bgp_inter_region_cost": "",
"delete_bgp_always_compare_med": false,
"delete_default_routes_on_create": false,
"description": "",
"enable_ula_internal_ipv6": false,
"gateway_ipv4": "",
"id": "projects/edn-asp-prod-625d6cfe/global/networks/default",
"internal_ipv6_range": "",
"mtu": 0,
"name": "default",
"network_firewall_policy_enforcement_order": "AFTER_CLASSIC_FIREWALL",
"network_id": "1516402592778361932",
"network_profile": "",
"numeric_id": "1516402592778361932",
"params": [],
"project": "edn-asp-prod-625d6cfe",
"routing_mode": "REGIONAL",
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/global/networks/default",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "uat",
"schema_version": 0,
"attributes": {
"auto_create_subnetworks": false,
"bgp_always_compare_med": false,
"bgp_best_path_selection_mode": "LEGACY",
"bgp_inter_region_cost": "",
"delete_bgp_always_compare_med": false,
"delete_default_routes_on_create": false,
"description": "",
"enable_ula_internal_ipv6": false,
"gateway_ipv4": "",
"id": "projects/edn-asp-uat-c4ef6fcc/global/networks/default",
"internal_ipv6_range": "",
"mtu": 0,
"name": "default",
"network_firewall_policy_enforcement_order": "AFTER_CLASSIC_FIREWALL",
"network_id": "7960939817142410535",
"network_profile": "",
"numeric_id": "7960939817142410535",
"params": [],
"project": "edn-asp-uat-c4ef6fcc",
"routing_mode": "REGIONAL",
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-uat-c4ef6fcc/global/networks/default",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_compute_subnetwork",
"name": "subnet",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"allow_subnet_cidr_routes_overlap": false,
"creation_timestamp": "2026-03-01T12:33:51.936-08:00",
"description": "",
"external_ipv6_prefix": "",
"fingerprint": null,
"gateway_address": "10.0.0.1",
"id": "projects/edn-asp-dev-d999ec05/regions/us-central1/subnetworks/default",
"internal_ipv6_prefix": "",
"ip_cidr_range": "10.0.0.0/20",
"ip_collection": null,
"ipv6_access_type": "",
"ipv6_cidr_range": "",
"ipv6_gce_endpoint": "",
"log_config": [],
"name": "default",
"network": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/global/networks/default",
"params": [],
"private_ip_google_access": true,
"private_ipv6_google_access": "DISABLE_GOOGLE_ACCESS",
"project": "edn-asp-dev-d999ec05",
"purpose": "PRIVATE",
"region": "us-central1",
"reserved_internal_range": "",
"role": "",
"secondary_ip_range": [],
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/regions/us-central1/subnetworks/default",
"send_secondary_ip_range_if_empty": null,
"stack_type": "IPV4_ONLY",
"state": "",
"subnetwork_id": 3303005436252855360,
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_compute_network.vpc",
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"allow_subnet_cidr_routes_overlap": false,
"creation_timestamp": "2026-03-01T12:33:51.873-08:00",
"description": "",
"external_ipv6_prefix": "",
"fingerprint": null,
"gateway_address": "10.0.0.1",
"id": "projects/edn-asp-prod-625d6cfe/regions/us-central1/subnetworks/default",
"internal_ipv6_prefix": "",
"ip_cidr_range": "10.0.0.0/20",
"ip_collection": null,
"ipv6_access_type": "",
"ipv6_cidr_range": "",
"ipv6_gce_endpoint": "",
"log_config": [],
"name": "default",
"network": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/global/networks/default",
"params": [],
"private_ip_google_access": true,
"private_ipv6_google_access": "DISABLE_GOOGLE_ACCESS",
"project": "edn-asp-prod-625d6cfe",
"purpose": "PRIVATE",
"region": "us-central1",
"reserved_internal_range": "",
"role": "",
"secondary_ip_range": [],
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/regions/us-central1/subnetworks/default",
"send_secondary_ip_range_if_empty": null,
"stack_type": "IPV4_ONLY",
"state": "",
"subnetwork_id": 8821798237041663040,
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_compute_network.vpc",
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "uat",
"schema_version": 0,
"attributes": {
"allow_subnet_cidr_routes_overlap": false,
"creation_timestamp": "2026-03-01T17:11:59.641-08:00",
"description": "",
"external_ipv6_prefix": "",
"fingerprint": null,
"gateway_address": "10.0.0.1",
"id": "projects/edn-asp-uat-c4ef6fcc/regions/us-central1/subnetworks/default",
"internal_ipv6_prefix": "",
"ip_cidr_range": "10.0.0.0/20",
"ip_collection": null,
"ipv6_access_type": "",
"ipv6_cidr_range": "",
"ipv6_gce_endpoint": "",
"log_config": [],
"name": "default",
"network": "https://www.googleapis.com/compute/v1/projects/edn-asp-uat-c4ef6fcc/global/networks/default",
"params": [],
"private_ip_google_access": true,
"private_ipv6_google_access": "DISABLE_GOOGLE_ACCESS",
"project": "edn-asp-uat-c4ef6fcc",
"purpose": "PRIVATE",
"region": "us-central1",
"reserved_internal_range": "",
"role": "",
"secondary_ip_range": [],
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-uat-c4ef6fcc/regions/us-central1/subnetworks/default",
"send_secondary_ip_range_if_empty": null,
"stack_type": "IPV4_ONLY",
"state": "",
"subnetwork_id": 4310926096167689520,
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_compute_network.vpc",
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_project",
"name": "project",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 1,
"attributes": {
"auto_create_network": true,
"billing_account": "01921B-5DFCDA-E2884B",
"deletion_policy": "PREVENT",
"effective_labels": {
"environment": "dev",
"goog-terraform-provisioned": "true"
},
"folder_id": "",
"id": "projects/edn-asp-dev-d999ec05",
"labels": {
"environment": "dev"
},
"name": "edn-asp-dev",
"number": "287152172717",
"org_id": "201562013677",
"project_id": "edn-asp-dev-d999ec05",
"tags": null,
"terraform_labels": {
"environment": "dev",
"goog-terraform-provisioned": "true"
},
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6NjAwMDAwMDAwMDAwLCJyZWFkIjo2MDAwMDAwMDAwMDAsInVwZGF0ZSI6NjAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0=",
"dependencies": [
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 1,
"attributes": {
"auto_create_network": true,
"billing_account": "01921B-5DFCDA-E2884B",
"deletion_policy": "PREVENT",
"effective_labels": {
"environment": "prod",
"goog-terraform-provisioned": "true"
},
"folder_id": "",
"id": "projects/edn-asp-prod-625d6cfe",
"labels": {
"environment": "prod"
},
"name": "edn-asp-prod",
"number": "539829660467",
"org_id": "201562013677",
"project_id": "edn-asp-prod-625d6cfe",
"tags": null,
"terraform_labels": {
"environment": "prod",
"goog-terraform-provisioned": "true"
},
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6NjAwMDAwMDAwMDAwLCJyZWFkIjo2MDAwMDAwMDAwMDAsInVwZGF0ZSI6NjAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0=",
"dependencies": [
"random_id.project_suffix"
]
},
{
"index_key": "uat",
"schema_version": 1,
"attributes": {
"auto_create_network": true,
"billing_account": "01921B-5DFCDA-E2884B",
"deletion_policy": "PREVENT",
"effective_labels": {
"environment": "uat",
"goog-terraform-provisioned": "true"
},
"folder_id": "",
"id": "projects/edn-asp-uat-c4ef6fcc",
"labels": {
"environment": "uat"
},
"name": "edn-asp-uat",
"number": "165264029976",
"org_id": "201562013677",
"project_id": "edn-asp-uat-c4ef6fcc",
"tags": null,
"terraform_labels": {
"environment": "uat",
"goog-terraform-provisioned": "true"
},
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6NjAwMDAwMDAwMDAwLCJyZWFkIjo2MDAwMDAwMDAwMDAsInVwZGF0ZSI6NjAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0=",
"dependencies": [
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_project_service",
"name": "apis",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev-cloudbilling.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/cloudbilling.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "cloudbilling.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-cloudresourcemanager.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/cloudresourcemanager.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "cloudresourcemanager.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-compute.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/compute.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "compute.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-iam.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/iam.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "iam.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-servicemanagement.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/servicemanagement.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "servicemanagement.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-cloudbilling.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/cloudbilling.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "cloudbilling.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-cloudresourcemanager.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/cloudresourcemanager.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "cloudresourcemanager.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-compute.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/compute.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "compute.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-iam.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/iam.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "iam.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-servicemanagement.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/servicemanagement.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "servicemanagement.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "uat-cloudbilling.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-uat-c4ef6fcc/cloudbilling.googleapis.com",
"project": "edn-asp-uat-c4ef6fcc",
"service": "cloudbilling.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "uat-cloudresourcemanager.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-uat-c4ef6fcc/cloudresourcemanager.googleapis.com",
"project": "edn-asp-uat-c4ef6fcc",
"service": "cloudresourcemanager.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "uat-compute.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-uat-c4ef6fcc/compute.googleapis.com",
"project": "edn-asp-uat-c4ef6fcc",
"service": "compute.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "uat-iam.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-uat-c4ef6fcc/iam.googleapis.com",
"project": "edn-asp-uat-c4ef6fcc",
"service": "iam.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "uat-servicemanagement.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-uat-c4ef6fcc/servicemanagement.googleapis.com",
"project": "edn-asp-uat-c4ef6fcc",
"service": "servicemanagement.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "random_id",
"name": "project_suffix",
"provider": "provider[\"registry.terraform.io/hashicorp/random\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"b64_std": "2ZnsBQ==",
"b64_url": "2ZnsBQ",
"byte_length": 4,
"dec": "3650743301",
"hex": "d999ec05",
"id": "2ZnsBQ",
"keepers": null,
"prefix": null
},
"sensitive_attributes": []
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"b64_std": "Yl1s/g==",
"b64_url": "Yl1s_g",
"byte_length": 4,
"dec": "1650289918",
"hex": "625d6cfe",
"id": "Yl1s_g",
"keepers": null,
"prefix": null
},
"sensitive_attributes": []
},
{
"index_key": "uat",
"schema_version": 0,
"attributes": {
"b64_std": "xO9vzA==",
"b64_url": "xO9vzA",
"byte_length": 4,
"dec": "3304026060",
"hex": "c4ef6fcc",
"id": "xO9vzA",
"keepers": null,
"prefix": null
},
"sensitive_attributes": []
}
]
}
],
"check_results": null
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

critical

Terraform state files (.tfstate) should not be committed to version control. They can contain sensitive information about your infrastructure and are specific to a particular run. Committing them can lead to security risks and merge conflicts. Please remove this file from the repository and add *.tfstate and *.tfstate.backup to your .gitignore file. For collaboration, it is highly recommended to use a remote backend for storing Terraform state, such as a Google Cloud Storage bucket.

Comment on lines +1 to +486
{
"version": 4,
"terraform_version": "1.8.3",
"serial": 22,
"lineage": "950f8d90-63ba-0bf3-1779-e06198f422b8",
"outputs": {},
"resources": [
{
"mode": "managed",
"type": "google_compute_network",
"name": "vpc",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"auto_create_subnetworks": false,
"bgp_always_compare_med": false,
"bgp_best_path_selection_mode": "LEGACY",
"bgp_inter_region_cost": "",
"delete_bgp_always_compare_med": false,
"delete_default_routes_on_create": false,
"description": "",
"enable_ula_internal_ipv6": false,
"gateway_ipv4": "",
"id": "projects/edn-asp-dev-d999ec05/global/networks/default",
"internal_ipv6_range": "",
"mtu": 0,
"name": "default",
"network_firewall_policy_enforcement_order": "AFTER_CLASSIC_FIREWALL",
"network_id": "6722168448933764172",
"network_profile": "",
"numeric_id": "6722168448933764172",
"params": [],
"project": "edn-asp-dev-d999ec05",
"routing_mode": "REGIONAL",
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/global/networks/default",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"auto_create_subnetworks": false,
"bgp_always_compare_med": false,
"bgp_best_path_selection_mode": "LEGACY",
"bgp_inter_region_cost": "",
"delete_bgp_always_compare_med": false,
"delete_default_routes_on_create": false,
"description": "",
"enable_ula_internal_ipv6": false,
"gateway_ipv4": "",
"id": "projects/edn-asp-prod-625d6cfe/global/networks/default",
"internal_ipv6_range": "",
"mtu": 0,
"name": "default",
"network_firewall_policy_enforcement_order": "AFTER_CLASSIC_FIREWALL",
"network_id": "1516402592778361932",
"network_profile": "",
"numeric_id": "1516402592778361932",
"params": [],
"project": "edn-asp-prod-625d6cfe",
"routing_mode": "REGIONAL",
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/global/networks/default",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_compute_subnetwork",
"name": "subnet",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"allow_subnet_cidr_routes_overlap": false,
"creation_timestamp": "2026-03-01T12:33:51.936-08:00",
"description": "",
"external_ipv6_prefix": "",
"fingerprint": null,
"gateway_address": "10.0.0.1",
"id": "projects/edn-asp-dev-d999ec05/regions/us-central1/subnetworks/default",
"internal_ipv6_prefix": "",
"ip_cidr_range": "10.0.0.0/20",
"ip_collection": null,
"ipv6_access_type": "",
"ipv6_cidr_range": "",
"ipv6_gce_endpoint": "",
"log_config": [],
"name": "default",
"network": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/global/networks/default",
"params": [],
"private_ip_google_access": true,
"private_ipv6_google_access": "DISABLE_GOOGLE_ACCESS",
"project": "edn-asp-dev-d999ec05",
"purpose": "PRIVATE",
"region": "us-central1",
"reserved_internal_range": "",
"role": "",
"secondary_ip_range": [],
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-dev-d999ec05/regions/us-central1/subnetworks/default",
"send_secondary_ip_range_if_empty": null,
"stack_type": "IPV4_ONLY",
"state": "",
"subnetwork_id": 3303005436252855360,
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_compute_network.vpc",
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"allow_subnet_cidr_routes_overlap": false,
"creation_timestamp": "2026-03-01T12:33:51.873-08:00",
"description": "",
"external_ipv6_prefix": "",
"fingerprint": null,
"gateway_address": "10.0.0.1",
"id": "projects/edn-asp-prod-625d6cfe/regions/us-central1/subnetworks/default",
"internal_ipv6_prefix": "",
"ip_cidr_range": "10.0.0.0/20",
"ip_collection": null,
"ipv6_access_type": "",
"ipv6_cidr_range": "",
"ipv6_gce_endpoint": "",
"log_config": [],
"name": "default",
"network": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/global/networks/default",
"params": [],
"private_ip_google_access": true,
"private_ipv6_google_access": "DISABLE_GOOGLE_ACCESS",
"project": "edn-asp-prod-625d6cfe",
"purpose": "PRIVATE",
"region": "us-central1",
"reserved_internal_range": "",
"role": "",
"secondary_ip_range": [],
"self_link": "https://www.googleapis.com/compute/v1/projects/edn-asp-prod-625d6cfe/regions/us-central1/subnetworks/default",
"send_secondary_ip_range_if_empty": null,
"stack_type": "IPV4_ONLY",
"state": "",
"subnetwork_id": 8821798237041663040,
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInVwZGF0ZSI6MTIwMDAwMDAwMDAwMH19",
"dependencies": [
"google_compute_network.vpc",
"google_project.project",
"google_project_service.apis",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_project",
"name": "project",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 1,
"attributes": {
"auto_create_network": true,
"billing_account": "01921B-5DFCDA-E2884B",
"deletion_policy": "PREVENT",
"effective_labels": {
"environment": "dev",
"goog-terraform-provisioned": "true"
},
"folder_id": "",
"id": "projects/edn-asp-dev-d999ec05",
"labels": {
"environment": "dev"
},
"name": "edn-asp-dev",
"number": "287152172717",
"org_id": "201562013677",
"project_id": "edn-asp-dev-d999ec05",
"tags": null,
"terraform_labels": {
"environment": "dev",
"goog-terraform-provisioned": "true"
},
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6NjAwMDAwMDAwMDAwLCJyZWFkIjo2MDAwMDAwMDAwMDAsInVwZGF0ZSI6NjAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0=",
"dependencies": [
"random_id.project_suffix"
]
},
{
"index_key": "prod",
"schema_version": 1,
"attributes": {
"auto_create_network": true,
"billing_account": "01921B-5DFCDA-E2884B",
"deletion_policy": "PREVENT",
"effective_labels": {
"environment": "prod",
"goog-terraform-provisioned": "true"
},
"folder_id": "",
"id": "projects/edn-asp-prod-625d6cfe",
"labels": {
"environment": "prod"
},
"name": "edn-asp-prod",
"number": "539829660467",
"org_id": "201562013677",
"project_id": "edn-asp-prod-625d6cfe",
"tags": null,
"terraform_labels": {
"environment": "prod",
"goog-terraform-provisioned": "true"
},
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjo2MDAwMDAwMDAwMDAsImRlbGV0ZSI6NjAwMDAwMDAwMDAwLCJyZWFkIjo2MDAwMDAwMDAwMDAsInVwZGF0ZSI6NjAwMDAwMDAwMDAwfSwic2NoZW1hX3ZlcnNpb24iOiIxIn0=",
"dependencies": [
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "google_project_service",
"name": "apis",
"provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
"instances": [
{
"index_key": "dev-cloudbilling.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/cloudbilling.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "cloudbilling.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-cloudresourcemanager.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/cloudresourcemanager.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "cloudresourcemanager.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-compute.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/compute.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "compute.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-iam.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/iam.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "iam.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "dev-servicemanagement.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-dev-d999ec05/servicemanagement.googleapis.com",
"project": "edn-asp-dev-d999ec05",
"service": "servicemanagement.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-cloudbilling.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/cloudbilling.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "cloudbilling.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-cloudresourcemanager.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/cloudresourcemanager.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "cloudresourcemanager.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-compute.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/compute.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "compute.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-iam.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/iam.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "iam.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
},
{
"index_key": "prod-servicemanagement.googleapis.com",
"schema_version": 0,
"attributes": {
"disable_dependent_services": null,
"disable_on_destroy": null,
"id": "edn-asp-prod-625d6cfe/servicemanagement.googleapis.com",
"project": "edn-asp-prod-625d6cfe",
"service": "servicemanagement.googleapis.com",
"timeouts": null
},
"sensitive_attributes": [],
"private": "eyJlMmJmYjczMC1lY2FhLTExZTYtOGY4OC0zNDM2M2JjN2M0YzAiOnsiY3JlYXRlIjoxMjAwMDAwMDAwMDAwLCJkZWxldGUiOjEyMDAwMDAwMDAwMDAsInJlYWQiOjYwMDAwMDAwMDAwMCwidXBkYXRlIjoxMjAwMDAwMDAwMDAwfX0=",
"dependencies": [
"google_project.project",
"random_id.project_suffix"
]
}
]
},
{
"mode": "managed",
"type": "random_id",
"name": "project_suffix",
"provider": "provider[\"registry.terraform.io/hashicorp/random\"]",
"instances": [
{
"index_key": "dev",
"schema_version": 0,
"attributes": {
"b64_std": "2ZnsBQ==",
"b64_url": "2ZnsBQ",
"byte_length": 4,
"dec": "3650743301",
"hex": "d999ec05",
"id": "2ZnsBQ",
"keepers": null,
"prefix": null
},
"sensitive_attributes": []
},
{
"index_key": "prod",
"schema_version": 0,
"attributes": {
"b64_std": "Yl1s/g==",
"b64_url": "Yl1s_g",
"byte_length": 4,
"dec": "1650289918",
"hex": "625d6cfe",
"id": "Yl1s_g",
"keepers": null,
"prefix": null
},
"sensitive_attributes": []
}
]
}
],
"check_results": null
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

critical

Terraform state backup files (.tfstate.backup) should not be committed to version control. They can contain sensitive information and are not meant to be shared via Git. Please remove this file and ensure *.tfstate* is in your .gitignore.


project = google_project.project[each.key].project_id
name = "default"
ip_cidr_range = "10.0.0.0/20"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The ip_cidr_range is hardcoded to "10.0.0.0/20" for all environments (dev, uat, prod). This creates overlapping IP address spaces, which will prevent you from peering these VPCs in the future. Each environment should have a unique CIDR range.

I suggest defining a map of CIDR ranges in your locals block and referencing it here. For example:

locals {
  // ...
  subnet_cidrs = {
    dev  = "10.10.0.0/20"
    uat  = "10.20.0.0/20"
    prod = "10.30.0.0/20"
  }
}
  ip_cidr_range            = local.subnet_cidrs[each.key]


# Sets environment variables in the workspace
env = {
PROJECT_ID = "edn-base";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This hardcoded PROJECT_ID can be misleading and causes issues with the setup_dev_env.sh script. The setup script is designed to add the correct PROJECT_ID to this file, but its current implementation will add a duplicate entry instead of replacing this one if the value differs.

I recommend removing this line. The setup script will then correctly add the user's configured project ID to the env block on the first run.

Comment on lines +242 to +243
alias tf=terraform
alias more=less
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

These alias commands will not have any effect in the user's shell after the script finishes executing, as they are defined in a subshell that is destroyed when the script exits.

To make these aliases available to the user, you should instruct them to add them to their shell's startup file (e.g., ~/.bashrc, ~/.zshrc). I recommend removing these lines from the script.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant