Skip to content

Commit

Permalink
Merge pull request #1 from zeroae/i/fix-precommit
Browse files Browse the repository at this point in the history
Remove typo in examples/complete
  • Loading branch information
sodre authored Jan 3, 2021
2 parents deee502 + ded3d6a commit 7ef3b60
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
5 changes: 2 additions & 3 deletions examples/complete/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,16 @@ module "encrypt" {

public_key_pem = tls_private_key.this.public_key_pem
content_base64 = base64encode(random_password.this.result)
x = file
}


output "generated" {
description = "The random generated password."
value = random_password.this.result
value = random_password.this.result
}

output "decrypted" {
description = "The same random password after it was encrypted and then decrypted."
value = rsadecrypt(module.encrypt.result, tls_private_key.this.private_key_pem)
value = rsadecrypt(module.encrypt.result, tls_private_key.this.private_key_pem)
}

2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module "encrypt" {
source = "matti/resource/shell"
source = "matti/resource/shell"
version = "1.1.0"
environment = {
PUBLIC_KEY_PEM = var.public_key_pem
Expand Down
2 changes: 1 addition & 1 deletion outputs.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
output "result" {
description = "Encrypted content in Base64-encoded format."
value = [module.encrypt.stdout][module.encrypt.exitstatus]
value = [module.encrypt.stdout][module.encrypt.exitstatus]
}
4 changes: 2 additions & 2 deletions variables.tf
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
variable "public_key_pem" {
type = string
type = string
description = "The RSA public key to use for encryption."
}

variable "content_base64" {
type = string
type = string
description = "Base64-encoded data to be encrypted."
}

0 comments on commit 7ef3b60

Please sign in to comment.