Page MenuHomeSoftware Heritage

proxmox/terraform: Align production nodes declaration with current module version
ClosedPublic

Authored by ardumont on Oct 8 2020, 11:35 AM.

Details

Summary

Just aligning the production declaration with the current "node module" interface.

So the terraform plan actually "compiles" instead of possibly breaking [1]

[1]*possibly* because i did not check but the old declaration could not have worked given the evolution of that module

Test Plan

terraform plan

P822

Diff Detail

Repository
rSPRE sysadm-provisioning
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

proxmox/terraform/zookeeper.tf
82

no need, that's the default.
plus it's now a storages declaration.

vsellier added inline comments.
proxmox/terraform/zookeeper.tf
46

The vmid for zookeeper3 is 102, I suppose it must be the same on the tf.

proxmox/terraform/zookeeper.tf
46

oh yes, thanks.

ardumont edited the test plan for this revision. (Show Details)

Fix zookeeper3 vmid

Refactor some more.

terraform is aggregating all the .tf file into one. So we can leverage this to
declare a common state to be shared in the common.tf file. This way, no need to
duplicate the local.config dictionary.

Add terraform.tfstate for the production nodes as well

ardumont retitled this revision from proxmox/terraform/production: Align declaration with module to proxmox/terraform: Align production nodes declaration with current module version.
ardumont edited the summary of this revision. (Show Details)

๐Ÿ‘ it looks synchronized

โžœ  terraform git:(arcpatch-D4197) terraform  plan -no-color | grep -E -e "^(\s)+[~+-]" -e "(name|target_node)\s+="
  ~ update in-place
  ~ resource "proxmox_vm_qemu" "node" {
        name         = "kelvingrove"
        target_node  = "hypervisor3"
      + vmid         = 123
  ~ resource "proxmox_vm_qemu" "node" {
        name         = "zookeeper1"
        target_node  = "hypervisor3"
      + vmid         = 125
  ~ resource "proxmox_vm_qemu" "node" {
        name         = "zookeeper2"
        target_node  = "branly"
      + vmid         = 124
  ~ resource "proxmox_vm_qemu" "node" {
        name         = "zookeeper3"
        target_node  = "beaubourg"
      + vmid         = 102
This revision is now accepted and ready to land.Oct 15 2020, 9:34 AM
ardumont edited the summary of this revision. (Show Details)