Skip to content

Commit

Permalink
PRODENG-2553 use upstream provision for smoke test
Browse files Browse the repository at this point in the history
- switch smoke testing to use the published provision module
  - cleanup key planning

Signed-off-by: James Nesbitt <[email protected]>
  • Loading branch information
james-nesbitt committed Mar 5, 2024
1 parent 344be50 commit fe3b2d9
Show file tree
Hide file tree
Showing 32 changed files with 12 additions and 1,274 deletions.
8 changes: 3 additions & 5 deletions examples/tf-aws/launchpad/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,12 @@

# our module puts a private ssh key into this folder.
*.key
*.pem

# Terraform stuff
terraform.tfstate*

# SSH-KEYS
./ssh-keys/

.terraform/
*.tfvars
.terraform

launchpad.yaml

14 changes: 5 additions & 9 deletions examples/tf-aws/launchpad/key.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,15 @@
#

module "key" {
source = "../provision/modules/key/ed25519"
source = "terraform-mirantis-modules/provision-aws/mirantis//modules/key/ed25519"

name = "${var.name}-common.pem"
name = "${var.name}-common"
tags = local.tags
}

locals {
pk_path = var.ssh_pk_location != "" ? join("/", [var.ssh_pk_location, module.key.name]) : "./ssh-keys/${module.key.name}"
}

resource "local_sensitive_file" "ssh_private_key" {
content = module.key.private_key
filename = local.pk_path
file_permission = "0777"
directory_permission = "0777"
filename = join("/", [var.ssh_pk_location, "${var.name}-common.pem"])
file_permission = "0600"
directory_permission = "0700"
}
2 changes: 1 addition & 1 deletion examples/tf-aws/launchpad/platform.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ locals {

module "platform" {
count = length(local.unique_used_platforms)
source = "../provision/modules/platform"
source = "terraform-mirantis-modules/provision-aws/mirantis//modules/platform"

platform_key = local.unique_used_platforms[count.index]
windows_password = var.windows_password
Expand Down
2 changes: 1 addition & 1 deletion examples/tf-aws/launchpad/provision.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ locals {

# PROVISION MACHINES/NETWORK
module "provision" {
source = "../provision"
source = "terraform-mirantis-modules/provision-aws/mirantis"

name = var.name
tags = local.tags
Expand Down
2 changes: 1 addition & 1 deletion examples/tf-aws/launchpad/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -56,5 +56,5 @@ variable "windows_password" {
variable "ssh_pk_location" {
description = "Location of the ssh private key"
type = string
default = ""
default = "."
}
38 changes: 0 additions & 38 deletions examples/tf-aws/provision/ingress.tf

This file was deleted.

64 changes: 0 additions & 64 deletions examples/tf-aws/provision/modules/ingress/lb.tf

This file was deleted.

5 changes: 0 additions & 5 deletions examples/tf-aws/provision/modules/ingress/output.tf

This file was deleted.

39 changes: 0 additions & 39 deletions examples/tf-aws/provision/modules/ingress/variables.tf

This file was deleted.

6 changes: 0 additions & 6 deletions examples/tf-aws/provision/modules/key/ed25519/README.md

This file was deleted.

15 changes: 0 additions & 15 deletions examples/tf-aws/provision/modules/key/ed25519/key.tf

This file was deleted.

14 changes: 0 additions & 14 deletions examples/tf-aws/provision/modules/key/ed25519/output.tf

This file was deleted.

11 changes: 0 additions & 11 deletions examples/tf-aws/provision/modules/key/ed25519/variables.tf

This file was deleted.

Empty file.
82 changes: 0 additions & 82 deletions examples/tf-aws/provision/modules/nodegroup/asg.tf

This file was deleted.

18 changes: 0 additions & 18 deletions examples/tf-aws/provision/modules/nodegroup/nodes.tf

This file was deleted.

8 changes: 0 additions & 8 deletions examples/tf-aws/provision/modules/nodegroup/output.tf

This file was deleted.

Loading

0 comments on commit fe3b2d9

Please sign in to comment.