Skip to content

feat: Add module to get a Key from the GCP Project - #84

Open
hbitoun-aneo wants to merge 10 commits into
revamp-cloudfrom
hb/gcp-get-key-module
Open

hbitoun-aneo wants to merge 10 commits into
revamp-cloudfrom
hb/gcp-get-key-module

Conversation

@hbitoun-aneo

Copy link
Copy Markdown
Contributor

No description provided.

@iadjadj iadjadj closed this Aug 31, 2023
@iadjadj iadjadj reopened this Aug 31, 2023
@iadjadj iadjadj changed the title feat: Add module to get a Key from the GCP project feat: Add module to get a Key from the GCP Project Aug 31, 2023

@lemaitre-aneo lemaitre-aneo left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This module should behave similarly than the kms module (except for resource creation). In particular, it should support multiple keys per key ring, and have the same output as the kms module.

@ftchawe-aneo ftchawe-aneo Sep 11, 2023

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The documentation should highlight the purpose of the module in the framework of ArmoniK

@lemaitre-aneo lemaitre-aneo left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I am not a big fan of the name of the module. I would prefer to have kms at the beginning of the name.

Here are some name suggestions (in order of personal preference):

  • kms-get
  • kms-data
  • kms-existing
  • kms-import
  • kms-external

type = string
variable "crypto_key_names" {
description = "The names of the crypto keys to retrieve from the GCP project."
type = list(string)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
type = list(string)
type = set(string)

@@ -1,4 +1,19 @@
output "my_crypto_key_output" {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
output "my_crypto_key_output" {
output "cyprto_keys" {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

There is a missing output compared to to the resource module:

output "crypto_key_ids" {
  description = "The Map of the created crypto keys."
  value       = { for key, value in google_kms_crypto_key.keys : key => value.id }
}

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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.

5 participants