Skip to content

Commit

Permalink
ci: update catalog json
Browse files Browse the repository at this point in the history
  • Loading branch information
huayuenh committed Jul 2, 2024
1 parent c18fd54 commit ce931fe
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 42 deletions.
1 change: 1 addition & 0 deletions code-engine/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ module "prereqs" {
iam_api_key_secret_name = var.pipeline_ibmcloud_api_key_secret_name
signing_key_secret_name = var.ci_signing_key_secret_name
signing_certifcate_secret_name = var.cd_code_signing_cert_secret_name
sm_exists = var.enable_secrets_manager
}

module "devsecops_ci_toolchain" {
Expand Down
43 changes: 4 additions & 39 deletions ibm_catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -337,14 +337,14 @@
"key": "create_signing_key",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add a `signing_key`to the Secrets Provider.",
"description": "Experimental. Set to `true` to create and add a `signing_key`to the Secrets Provider.",
"required": false
},
{
"key": "create_signing_certificate",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add the `signing-certificate` to the Secrets Provider.",
"description": "Experimental. Set to `true` to create and add the `signing-certificate` to the Secrets Provider.",
"required": false
},
{
Expand Down Expand Up @@ -4643,14 +4643,14 @@
"key": "create_signing_key",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add a `signing_key`to the Secrets Provider.",
"description": "Experimental. Set to `true` to create and add a `signing_key`to the Secrets Provider.",
"required": false
},
{
"key": "create_signing_certificate",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add the `signing-certificate` to the Secrets Provider.",
"description": "Experimental. Set to `true` to create and add the `signing-certificate` to the Secrets Provider.",
"required": false
},
{
Expand Down Expand Up @@ -4681,41 +4681,6 @@
"description": "Set the Cloud Object Storage endpoint for accessing your COS bucket. This setting sets the same endpoint for COS in the CI, CD, and CC toolchains. See `ci_cos_endpoint`, `cd_cos_endpoint`, and `cc_cos_endpoint` to set the endpoints separately.",
"required": false
},
{
"key": "create_ibmcloud_api_key",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add an `ibmcloud-api-key` to the Secrets Provider.",
"required": false
},
{
"key": "create_cos_api_key",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add a `cos-api-key` to the Secrets Provider.",
"required": false
},
{
"key": "create_signing_key",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add a `signing_key`to the Secrets Provider.",
"required": false
},
{
"key": "create_signing_certificate",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create and add the `signing-certificate` to the Secrets Provider.",
"required": false
},
{
"key": "create_sm_secret_group",
"type": "boolean",
"default_value": false,
"description": "Set to `true` to create a secrets group in Secrets Manager.",
"required": false
},
{
"key": "repo_git_token_secret_name",
"type": "string",
Expand Down
1 change: 1 addition & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ module "prereqs" {
iam_api_key_secret_name = var.pipeline_ibmcloud_api_key_secret_name
signing_key_secret_name = var.ci_signing_key_secret_name
signing_certifcate_secret_name = var.cd_code_signing_cert_secret_name
sm_exists = var.enable_secrets_manager
}

module "devsecops_ci_toolchain" {
Expand Down
2 changes: 1 addition & 1 deletion prereqs/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ data "external" "signing_keys" {
####### SECRETS MANAGER #####################

data "ibm_resource_instance" "sm_instance" {
count = (var.sm_name != "") ? 1 : 0
count = ((var.sm_name != "") && (var.sm_exists == true)) ? 1 : 0
name = var.sm_name
location = var.sm_location
resource_group_id = var.resource_group_id
Expand Down
10 changes: 8 additions & 2 deletions prereqs/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ variable "create_cos_api_key" {

variable "create_signing_key" {
type = bool
description = "Set to `true` to create and add a `signing_key`to the Secrets Provider."
description = "Experimental. Set to `true` to create and add a `signing_key`to the Secrets Provider."
default = false
}

variable "create_signing_certificate" {
type = bool
description = "Set to `true` to create and add the `signing-certificate` to the Secrets Provider."
description = "Experimental. Set to `true` to create and add the `signing-certificate` to the Secrets Provider."
default = false
}

Expand All @@ -40,6 +40,12 @@ variable "create_sm_secret_group" {
default = false
}

variable "sm_exists" {
description = "Only connect to the Secrets Manager instance if it has been enabled for the toolchain."
type = bool
default = false
}

variable "sm_location" {
type = string
description = "The region location of the Secrets Manager instance."
Expand Down

0 comments on commit ce931fe

Please sign in to comment.