diff --git a/cli/docs/lacework_generate_cloud-account_gcp.md b/cli/docs/lacework_generate_cloud-account_gcp.md index af9802869..53c08826b 100644 --- a/cli/docs/lacework_generate_cloud-account_gcp.md +++ b/cli/docs/lacework_generate_cloud-account_gcp.md @@ -48,11 +48,11 @@ lacework generate cloud-account gcp [flags] --custom_filter string Audit Log filter which supersedes all other filter options when defined --enable_ubla enable universal bucket level access(ubla) (default true) --existing_bucket_name string specify existing bucket name + --existing_pub_sub_subscription_name string specify existing pub/sub subscription name + --existing_pub_sub_topic_id string specify existing pub/sub topic id --existing_service_account_name string specify existing service account name --existing_service_account_private_key string specify existing service account private key (base64 encoded) --existing_sink_name string specify existing sink name - --existing_pub_sub_topic_id string specify existing pub/sub topic id - --existing_pub_sub_subscription_name string specify existing pub/sub subscription name -e, --folders_to_exclude stringArray List of root folders to exclude for an organization-level integration -i, --folders_to_include stringArray list of root folders to include for an organization-level integration --google_workspace_filter filter out Google Workspace login logs from GCP Audit Log sinks (default true) diff --git a/integration/gcp_generation_test.go b/integration/gcp_generation_test.go index dcb9751b2..e9740e06e 100644 --- a/integration/gcp_generation_test.go +++ b/integration/gcp_generation_test.go @@ -184,7 +184,7 @@ func TestGenerationPubSubAuditlogOnlyGcp(t *testing.T) { } // Test pub-sub audit log with existing topic and subscription -func TestGenerationPubSubAuditlogExistingTopicAndSubscriptionGcp(t *testing.T) { +func TestGenerationPubSubAuditLogExistingTopicAndSubscriptionGcp(t *testing.T) { os.Setenv("LW_NOCACHE", "true") defer os.Setenv("LW_NOCACHE", "") var final string @@ -203,9 +203,9 @@ func TestGenerationPubSubAuditlogExistingTopicAndSubscriptionGcp(t *testing.T) { MsgRsp{cmd.QuestionGcpUseExistingSink, "y"}, MsgRsp{cmd.QuestionGcpExistingSinkName, "sink"}, MsgRsp{cmd.QuestionGcpUseExistingPubSubTopic, "y"}, - MsgRsp{cmd.QuestionGcpExistingPubSubTopicId, "topicMcTopicFace"}, + MsgRsp{cmd.QuestionGcpExistingPubSubTopicId, "topic"}, MsgRsp{cmd.QuestionGcpUseExistingPubSubSubscription, "y"}, - MsgRsp{cmd.QuestionGcpExistingPubSubSubscriptionName, "subscriptionMcSubscriptionFace"}, + MsgRsp{cmd.QuestionGcpExistingPubSubSubscriptionName, "subscription"}, MsgRsp{cmd.QuestionGcpCustomFilter, ""}, MsgRsp{cmd.QuestionGcpAnotherAdvancedOpt, "n"}, MsgRsp{cmd.QuestionRunTfPlan, "n"}, @@ -223,8 +223,8 @@ func TestGenerationPubSubAuditlogExistingTopicAndSubscriptionGcp(t *testing.T) { buildTf, _ := gcp.NewTerraform(false, true, true, gcp.WithProjectId(projectId), gcp.WithExistingLogSinkName("sink"), - gcp.WithExistingPubSubTopicId("topicMcTopicFace"), - gcp.WithExistingPubSubSubscriptionName("subscriptionMcSubscriptionFace"), + gcp.WithExistingPubSubTopicId("topic"), + gcp.WithExistingPubSubSubscriptionName("subscription"), ).Generate() assert.Equal(t, buildTf, tfResult) } diff --git a/integration/test_resources/help/generate_cloud-account_gcp b/integration/test_resources/help/generate_cloud-account_gcp index c02398f06..aae3e28fd 100644 --- a/integration/test_resources/help/generate_cloud-account_gcp +++ b/integration/test_resources/help/generate_cloud-account_gcp @@ -32,6 +32,8 @@ Flags: --custom_filter string Audit Log filter which supersedes all other filter options when defined --enable_ubla enable universal bucket level access(ubla) (default true) --existing_bucket_name string specify existing bucket name + --existing_pub_sub_subscription_name string specify existing pub/sub subscription name + --existing_pub_sub_topic_id string specify existing pub/sub topic id --existing_service_account_name string specify existing service account name --existing_service_account_private_key string specify existing service account private key (base64 encoded) --existing_sink_name string specify existing sink name