Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert to blueprint test skeleton for all stages and do a pipeline refactor #710

Merged
merged 105 commits into from
May 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
0c9070d
bootstrap go test
daniel-cit Apr 5, 2022
5acc18f
fix lint
daniel-cit Apr 5, 2022
5a7f4d8
add env var for missing input values
daniel-cit Apr 5, 2022
c3adba9
add sleep after test setup for enabling api propagation
daniel-cit Apr 5, 2022
5572084
increase sleep time to 3 minutes
daniel-cit Apr 5, 2022
128fa63
fix test assertion
daniel-cit Apr 5, 2022
d70dfb2
replicate env vars form converge to verify stage.
daniel-cit Apr 5, 2022
de7a9f4
fix type.
daniel-cit Apr 5, 2022
236892d
skip default verify
daniel-cit Apr 5, 2022
abe03d3
replicate env vars form converge to destroy stage.
daniel-cit Apr 5, 2022
47fea29
bump CFT version and update test
daniel-cit Apr 5, 2022
488ad0f
update go.mod file
daniel-cit Apr 5, 2022
a0158f5
add org test
daniel-cit Apr 6, 2022
28fdb07
add org test asserts
daniel-cit Apr 6, 2022
811c030
fix test
daniel-cit Apr 6, 2022
23f3a07
disable backend bucket
daniel-cit Apr 6, 2022
ec2bca0
fix domains to allow env var name
daniel-cit Apr 6, 2022
2539a0b
fix domains to allow value
daniel-cit Apr 6, 2022
6c44bef
add domains to allow to setup output
daniel-cit Apr 6, 2022
604c38a
add go envs tests
daniel-cit Apr 6, 2022
0af27ce
fix typo
daniel-cit Apr 6, 2022
80fc7ad
add tests for network, projects and app-infra
daniel-cit Apr 6, 2022
797b509
disable auto.tfvars files and set access_context_manager_policy_id
daniel-cit Apr 7, 2022
10f5eb4
wait for four minutes for api propagation
daniel-cit Apr 7, 2022
79663a6
add target_name_server_addresses to setup output
daniel-cit Apr 7, 2022
93d194d
update list of terraform files to disable
daniel-cit Apr 8, 2022
55aedcd
add access_context_manager_policy_id to env vars of step 4 projects
daniel-cit Apr 8, 2022
34de162
add export to export of previous terraform script outputs
daniel-cit Apr 11, 2022
1c0f891
read perimeter name from env var
daniel-cit Apr 11, 2022
6fcf50c
fix helper script
daniel-cit Apr 11, 2022
ec17c5f
source script to export variables
daniel-cit Apr 11, 2022
e70068b
export env var for the create stage of step 4 projects
daniel-cit Apr 11, 2022
7f448af
remove DefaultVerify from step 4 projects
daniel-cit Apr 11, 2022
9fcf547
fix typo
daniel-cit Apr 11, 2022
8d6c33c
add plugin version configuration for step 5
daniel-cit Apr 12, 2022
48bc9b1
set instance details to sensitive in step 5
daniel-cit Apr 12, 2022
009ed03
read service account from env var in step 5
daniel-cit Apr 12, 2022
7d81afe
add shared network step to integration tests
daniel-cit Apr 12, 2022
28d13b7
export access context manager policy id for network shared step
daniel-cit Apr 12, 2022
15b645c
fix lint issues
daniel-cit Apr 12, 2022
8e9dfa2
Merge branch 'master' into bpt-migration
daniel-cit Apr 13, 2022
aa61af0
remove kitchem and inspec code
daniel-cit Apr 13, 2022
48c4d05
fix default region configuration in the tests
daniel-cit Apr 13, 2022
d958368
read step 3-networks output in the test execution of step 4-projects
daniel-cit Apr 13, 2022
294807c
use gcloud to get the value of the access context manager policy ID
daniel-cit Apr 14, 2022
244da52
remove access_context_manager_policy_id from projects/shared
daniel-cit Apr 14, 2022
b5d13d1
delete export_vars.sh script
daniel-cit Apr 15, 2022
fcbcab5
add instructions and use cft cli
daniel-cit Apr 15, 2022
f5ad999
test new order of params
daniel-cit Apr 18, 2022
93b0678
add test-dir to the call to cft test in cloud buil bootstrap
daniel-cit Apr 18, 2022
0019439
restore usage of go test to run the integration steps
daniel-cit Apr 18, 2022
37dde51
test HubAndSpoke
daniel-cit Apr 18, 2022
e303e55
restore values for test organization
daniel-cit Apr 19, 2022
c9b24d6
remove commented code
daniel-cit Apr 19, 2022
6d02f8c
fix lint build configuration
daniel-cit Apr 19, 2022
c92da8e
use cft cli to run tests in the build
daniel-cit Apr 25, 2022
a3333fd
remove replicated code from org test
daniel-cit Apr 26, 2022
e888e38
remove unnecessary struct from network test
daniel-cit Apr 26, 2022
7bbdad4
fix code review items
daniel-cit Apr 26, 2022
e84c4bf
restore ci project name
daniel-cit Apr 26, 2022
4933f0b
restore call to helper function
daniel-cit Apr 26, 2022
ee3f929
restore all calls to helper function in int build
daniel-cit Apr 26, 2022
4c94d09
add missing call to helper function at app infra destroy stage
daniel-cit Apr 26, 2022
09f336b
add app infra tests
daniel-cit Apr 28, 2022
9de0af6
migrate gcp tests for the step 4-projects
daniel-cit Apr 29, 2022
27b984e
migrate gcloud tests for the step 4-projects
daniel-cit May 2, 2022
a194674
use gcloud.Runf if possible
daniel-cit May 2, 2022
dbea31c
simplify usage of gcloud methods
daniel-cit May 2, 2022
665c736
update go.mod
daniel-cit May 3, 2022
5ade401
migrate 3-networks tests
daniel-cit May 3, 2022
28eae00
fix variable names
daniel-cit May 3, 2022
8a920d6
migrate 3 shared tests
daniel-cit May 3, 2022
e59e4eb
migrate tests
daniel-cit May 3, 2022
b804e4e
fix subset assert
daniel-cit May 3, 2022
3266e1e
fix folder output value to remove 'folders/'
daniel-cit May 4, 2022
ad99151
remove unnused test attribute for perimeter env var
daniel-cit May 4, 2022
c1ceb43
fix access to last element of slice
daniel-cit May 4, 2022
9759ffd
update list of boolean org policies
daniel-cit May 4, 2022
a016d04
fix reading directory customer ID value
daniel-cit May 4, 2022
b307d11
add roles/resourcemanager.organizationViewe to the ci service account
daniel-cit May 4, 2022
1af3c30
skip restrictedDomain verify
daniel-cit May 4, 2022
f15277c
fix log sink tests, log bucket test, and hub and spoke tests
daniel-cit May 4, 2022
77a08af
fix typo in env test
daniel-cit May 4, 2022
e64ebb7
fix retrieval of monitoring_workspace_users group
daniel-cit May 5, 2022
525ceb1
fix assert.Contains base list
daniel-cit May 5, 2022
2f600d8
add restrictedDomain verification
daniel-cit May 5, 2022
bfb9593
fix cidrRange for shared test
daniel-cit May 5, 2022
528bb2c
fix monitoring_workspace_users output for testing
daniel-cit May 5, 2022
a3f588f
fix cloud router region in 3-networks/shared
daniel-cit May 5, 2022
3ea5fff
fix lint issue
daniel-cit May 5, 2022
648754a
fix firewall tests
daniel-cit May 5, 2022
3a1822b
get the len of the allowed ports array in the network test
daniel-cit May 5, 2022
58ec286
fix step 4 iam tests
daniel-cit May 5, 2022
b46cfe0
fix project iam test for base_shared_vpc_project
daniel-cit May 5, 2022
83a98f3
fix param for search of vpc host project id
daniel-cit May 5, 2022
3027380
fix param for search of restricted vpc host project id
daniel-cit May 6, 2022
a37eac5
increase provider request timeout to prevente dns policy error 409:Th…
daniel-cit May 8, 2022
8fa17f6
increase provider request timeout to 120s prevent dns policy error 40…
daniel-cit May 8, 2022
99e607d
use helper function to create list of strings
daniel-cit May 10, 2022
71b22a6
remove initialization of string field with empty string
daniel-cit May 10, 2022
63d0521
remove monitoring_workspace_users from 2-environments output
daniel-cit May 10, 2022
dcbf9b0
use Runf when passing a single parameter
daniel-cit May 10, 2022
8a627ef
remove task_helper_functions script from integration build
daniel-cit May 10, 2022
7f3df8f
set TF_VAR_group_email as a global env var in integration build yaml
daniel-cit May 10, 2022
00f907e
use proper service account in step 5-app-infra
daniel-cit May 11, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 0 additions & 125 deletions .kitchen.yml

This file was deleted.

4 changes: 2 additions & 2 deletions 3-networks/envs/development/providers.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ locals {
*****************************************/
provider "google" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}

provider "google-beta" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}
4 changes: 2 additions & 2 deletions 3-networks/envs/non-production/providers.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ locals {
*****************************************/
provider "google" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}

provider "google-beta" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}
4 changes: 2 additions & 2 deletions 3-networks/envs/production/providers.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ locals {
*****************************************/
provider "google" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}

provider "google-beta" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}
4 changes: 2 additions & 2 deletions 3-networks/envs/shared/providers.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ locals {
*****************************************/
provider "google" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}

provider "google-beta" {
impersonate_service_account = local.tf_sa
request_timeout = "60s"
request_timeout = "120s"
}
1 change: 1 addition & 0 deletions 5-app-infra/business_unit_1/development/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ output "instances_zones" {
output "instances_details" {
description = "List of details for compute instances"
value = module.base_shared_gce_instance.instances_details
sensitive = true
}

output "available_zones" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -14,7 +14,30 @@
* limitations under the License.
*/

output "dns_hub_project_id" {
value = module.shared.dns_hub_project_id
description = "The DNS hub project ID"
terraform {
required_version = ">= 0.13"

required_providers {

google = {
source = "hashicorp/google"
version = "~> 3.77"
}

google-beta = {
source = "hashicorp/google-beta"
version = "~> 3.77"
}

null = {
source = "hashicorp/null"
version = "~> 2.1"
}

random = {
source = "hashicorp/random"
version = "~> 2.3"
}

}
}
1 change: 1 addition & 0 deletions 5-app-infra/business_unit_1/non-production/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ output "instances_zones" {
output "instances_details" {
description = "List of details for compute instances"
value = module.base_shared_gce_instance.instances_details
sensitive = true
}

output "available_zones" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -14,14 +14,30 @@
* limitations under the License.
*/

module "bootstrap" {
source = "../../../0-bootstrap"
parent_folder = var.parent_folder
org_id = var.org_id
group_org_admins = var.group_email
group_billing_admins = var.group_email
billing_account = var.billing_account
org_project_creators = var.org_project_creators
project_prefix = var.project_prefix
bucket_prefix = var.bucket_prefix
terraform {
required_version = ">= 0.13"

required_providers {

google = {
source = "hashicorp/google"
version = "~> 3.77"
}

google-beta = {
source = "hashicorp/google-beta"
version = "~> 3.77"
}

null = {
source = "hashicorp/null"
version = "~> 2.1"
}

random = {
source = "hashicorp/random"
version = "~> 2.3"
}

}
}
1 change: 1 addition & 0 deletions 5-app-infra/business_unit_1/production/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ output "instances_zones" {
output "instances_details" {
description = "List of details for compute instances"
value = module.base_shared_gce_instance.instances_details
sensitive = true
}

output "available_zones" {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -14,23 +14,30 @@
* limitations under the License.
*/

variable "terraform_service_account" {
description = "The SA that will be used for creating projects."
}
terraform {
required_version = ">= 0.13"

variable "folder_prefix" {
description = "Name prefix to use for folders created."
type = string
default = "fldr"
}
required_providers {

variable "parent_folder" {
description = "Optional - if using a folder for testing."
type = string
default = ""
}
google = {
source = "hashicorp/google"
version = "~> 3.77"
}

google-beta = {
source = "hashicorp/google-beta"
version = "~> 3.77"
}

null = {
source = "hashicorp/null"
version = "~> 2.1"
}

random = {
source = "hashicorp/random"
version = "~> 2.3"
}

variable "org_id" {
description = "The organization id for the associated services"
type = string
}
}
Loading