diff --git a/.gitignore b/.gitignore index a0d2c74..df814a5 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,6 @@ .terraform .terraform* -!.terraform.lock.hcl +.terraform.lock.hcl ignition.bu terraform.tfstate terraform.tfstate.backup diff --git a/.terraform.lock.hcl b/.terraform.lock.hcl deleted file mode 100644 index e811f18..0000000 --- a/.terraform.lock.hcl +++ /dev/null @@ -1,190 +0,0 @@ -# This file is maintained automatically by "terraform init". -# Manual edits may be lost in future updates. - -provider "registry.terraform.io/cloudflare/cloudflare" { - version = "3.6.0" - constraints = "3.6.0" - hashes = [ - "h1:0ESwUqp8rhdP0Wy6rsauVruGF8z5JIytGD04vpc/cPs=", - "zh:00fd3e98ef0e8f0cba3ef640fb0353328c292e85076cfbcd582a6765a5e747bf", - "zh:2386a835a1f920db97ad597048244664b810694f81efd729484681e64811b95c", - "zh:2e892efeaac9244c20c8fc9e6971b7ec479b10232c11ab354523ce244badcada", - "zh:32c7ec995ecc8feaef7d2e304bdadda716358552520f5cb31ac8ad823876e777", - "zh:73be34d0abf19156ea256a976496351e082a9257fcedd7d2a180b2513d6d6134", - "zh:757fb3efbfdf2e912dcb7b3102e64cd8d2b378857e14933b95c1b9f8a051adf7", - "zh:7bb9acadfaf7e0fd2e256ba84e4642db7af3470a8ea3351d115fc284399de643", - "zh:7cedc56618b56d1bdde98bdf7c5167681b98907e7dfb7e2725f1ec36b6d3b416", - "zh:7d5ed91f3e843f687b78db0db6be57180b2f1799323636fe4d74c860b7a130c3", - "zh:83c75cf0ffa937654228b85bde542529e4ae1cc87af6abf0a1ece09108057bff", - "zh:93269070cbc52e4865e490291f798e07398fb4efe879b425821006c68dfa5e7d", - "zh:93d2467d9680d0d11028ec3a78ec8139afa18c45cff83b0e5aa84d8b9e5a91f2", - "zh:bb31aae955bc306b635d2592dcd07c37a863981caf450ffa7c8adb1cc8d70053", - "zh:c0f4324ff34349ce2ae0a8af81a04aec988f83ae7b876290ab7eb86d1a5d61af", - ] -} - -provider "registry.terraform.io/equinix/equinix" { - version = "1.14.1" - constraints = "1.14.1" - hashes = [ - "h1:k8eFYlT/bsI54TQOG84bzqWelZK8fNzvYIkJwd+cEnM=", - "zh:1b478c206ae88a3bfd4ab376ce19e5c577b8f3389005cc159bb041b6dc9e00b1", - "zh:24b793281076cd57ac42665d919406ba4077768db01b0f1f1e7daff814159a49", - "zh:35d2902215d27592ff6cbbe478910aa40474ee0f0875a42ea06a11b32cae4ff7", - "zh:3ca24f4c577042ef4232105eb92b18fd83e59e1a99955507526a7a96edcd83de", - "zh:4f0ef4b10eca14fc091be18547d125fdf687b290ec3925bfcb3006033a6d8155", - "zh:50fe98f600a1cb15fb1b7153a5f70a2432e2920b9d99498a327db7c81fdbaaec", - "zh:8a1619f0fb5aa0eebec1133a2e7795da503425252300ffd286587a91f1316bd5", - "zh:8baf418e8acb130e32ab0402bcc2545fd1d0ac8ad3d6d337f51acb70eb99719d", - "zh:9062cdbbd2bedf1ad1ace95eca13f962d6dd8deb6db2e25e153027098e1aa985", - "zh:bc9160faff9ddb9e532e6ae7c79f8e66163ba19eadc34b0975a0c7b0084db02b", - "zh:bf67edb2daae4fe6728e4f879aecd9b4130beb82c0ad79e4cd2b159b48c93c02", - "zh:c125746c76a8580a403c56b69d702d0831523cfea3b7a3889ffc48835b7403ce", - "zh:c6fe46df23138c80d70cec18a791f02ccdf5c6c0b77a3f85964c0ddd33ad0025", - "zh:dd50a69bb647668a5255db0d01e655dc708b1e3a0ea780db2efb2418a6599ccd", - ] -} - -provider "registry.terraform.io/hashicorp/aws" { - version = "3.76.1" - constraints = "~> 3.0" - hashes = [ - "h1:nrYpq9ne3FNUmjekbc0ayKE7wNu7BaMpV7oSC+qjAC4=", - "h1:z1+WjdwuRX8Aa9a7YKXErhZ5AuvoXiDq7FHts30sZak=", - "zh:1cf933104a641ffdb64d71a76806f4df35d19101b47e0eb02c9c36bd64bfdd2d", - "zh:273afaf908775ade6c9d32462938e7739ee8b00a0de2ef3cdddc5bc115bb1d4f", - "zh:2bc24ae989e38f575de034083082c69b41c54b8df69d35728853257c400ce0f4", - "zh:53ba88dbdaf9f818d35001c3d519a787f457283d9341f562dc3d0af51fd9606e", - "zh:5cdac7afea68bbd89d3bdb345d99470226482eff41f375f220fe338d2e5808da", - "zh:63127808890ac4be6cff6554985510b15ac715df698d550a3e722722dc56523c", - "zh:97a1237791f15373743189b078a0e0f2fa4dd7d7474077423376cd186312dc55", - "zh:9b12af85486a96aedd8d7984b0ff811a4b42e3d88dad1a3fb4c0b580d04fa425", - "zh:a4f625e97e5f25073c08080e4a619f959bc0149fc853a6b1b49ab41d58b59665", - "zh:b56cca54019237941f7614e8d2712586a6ab3092e8e9492c70f06563259171e9", - "zh:d4bc33bfd6ac78fb61e6d48a61c179907dfdbdf149b89fb97272c663989a7fcd", - "zh:e0089d73fa56d128c574601305634a774eebacf4a84babba71da10040cecf99a", - "zh:e957531f1d92a6474c9b02bd9200da91b99ba07a0ab761c8e3176400dd41721c", - "zh:eceb85818d57d8270db4df7564cf4ed51b5c650a361aaa017c42227158e1946b", - "zh:f565e5caa1b349ec404c6d03d01c68b02233f5485ed038d0aab810dd4023a880", - ] -} - -provider "registry.terraform.io/hashicorp/external" { - version = "2.3.1" - hashes = [ - "h1:9rJggijNdRdFk//ViQPGZdK0xu9XU/9qBDijNsZJMg0=", - "h1:gznGscVJ0USxy4CdihpjRKPsKvyGr/zqPvBoFLJTQDc=", - "zh:001e2886dc81fc98cf17cf34c0d53cb2dae1e869464792576e11b0f34ee92f54", - "zh:2eeac58dd75b1abdf91945ac4284c9ccb2bfb17fa9bdb5f5d408148ff553b3ee", - "zh:2fc39079ba61411a737df2908942e6970cb67ed2f4fb19090cd44ce2082903dd", - "zh:472a71c624952cff7aa98a7b967f6c7bb53153dbd2b8f356ceb286e6743bb4e2", - "zh:4cff06d31272aac8bc35e9b7faec42cf4554cbcbae1092eaab6ab7f643c215d9", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:7ed16ccd2049fa089616b98c0bd57219f407958f318f3c697843e2397ddf70df", - "zh:842696362c92bf2645eb85c739410fd51376be6c488733efae44f4ce688da50e", - "zh:8985129f2eccfd7f1841ce06f3bf2bbede6352ec9e9f926fbaa6b1a05313b326", - "zh:a5f0602d8ec991a5411ef42f872aa90f6347e93886ce67905c53cfea37278e05", - "zh:bf4ab82cbe5256dcef16949973bf6aa1a98c2c73a98d6a44ee7bc40809d002b8", - "zh:e70770be62aa70198fa899526d671643ff99eecf265bf1a50e798fc3480bd417", - ] -} - -provider "registry.terraform.io/hashicorp/local" { - version = "2.4.0" - hashes = [ - "h1:Bs7LAkV/iQTLv72j+cTMrvx2U3KyXrcVHaGbdns1NcE=", - "h1:ZUEYUmm2t4vxwzxy1BvN1wL6SDWrDxfH7pxtzX8c6d0=", - "zh:53604cd29cb92538668fe09565c739358dc53ca56f9f11312b9d7de81e48fab9", - "zh:66a46e9c508716a1c98efbf793092f03d50049fa4a83cd6b2251e9a06aca2acf", - "zh:70a6f6a852dd83768d0778ce9817d81d4b3f073fab8fa570bff92dcb0824f732", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:82a803f2f484c8b766e2e9c32343e9c89b91997b9f8d2697f9f3837f62926b35", - "zh:9708a4e40d6cc4b8afd1352e5186e6e1502f6ae599867c120967aebe9d90ed04", - "zh:973f65ce0d67c585f4ec250c1e634c9b22d9c4288b484ee2a871d7fa1e317406", - "zh:c8fa0f98f9316e4cfef082aa9b785ba16e36ff754d6aba8b456dab9500e671c6", - "zh:cfa5342a5f5188b20db246c73ac823918c189468e1382cb3c48a9c0c08fc5bf7", - "zh:e0e2b477c7e899c63b06b38cd8684a893d834d6d0b5e9b033cedc06dd7ffe9e2", - "zh:f62d7d05ea1ee566f732505200ab38d94315a4add27947a60afa29860822d3fc", - "zh:fa7ce69dde358e172bd719014ad637634bbdabc49363104f4fca759b4b73f2ce", - ] -} - -provider "registry.terraform.io/hashicorp/null" { - version = "3.2.1" - hashes = [ - "h1:tSj1mL6OQ8ILGqR2mDu7OYYYWf+hoir0pf9KAQ8IzO8=", - "h1:ydA0/SNRVB1o95btfshvYsmxA+jZFRZcvKzZSB+4S1M=", - "zh:58ed64389620cc7b82f01332e27723856422820cfd302e304b5f6c3436fb9840", - "zh:62a5cc82c3b2ddef7ef3a6f2fedb7b9b3deff4ab7b414938b08e51d6e8be87cb", - "zh:63cff4de03af983175a7e37e52d4bd89d990be256b16b5c7f919aff5ad485aa5", - "zh:74cb22c6700e48486b7cabefa10b33b801dfcab56f1a6ac9b6624531f3d36ea3", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:79e553aff77f1cfa9012a2218b8238dd672ea5e1b2924775ac9ac24d2a75c238", - "zh:a1e06ddda0b5ac48f7e7c7d59e1ab5a4073bbcf876c73c0299e4610ed53859dc", - "zh:c37a97090f1a82222925d45d84483b2aa702ef7ab66532af6cbcfb567818b970", - "zh:e4453fbebf90c53ca3323a92e7ca0f9961427d2f0ce0d2b65523cc04d5d999c2", - "zh:e80a746921946d8b6761e77305b752ad188da60688cfd2059322875d363be5f5", - "zh:fbdb892d9822ed0e4cb60f2fedbdbb556e4da0d88d3b942ae963ed6ff091e48f", - "zh:fca01a623d90d0cad0843102f9b8b9fe0d3ff8244593bd817f126582b52dd694", - ] -} - -provider "registry.terraform.io/hashicorp/random" { - version = "3.5.1" - hashes = [ - "h1:sZ7MTSD4FLekNN2wSNFGpM+5slfvpm5A/NLVZiB7CO0=", - "zh:04e3fbd610cb52c1017d282531364b9c53ef72b6bc533acb2a90671957324a64", - "zh:119197103301ebaf7efb91df8f0b6e0dd31e6ff943d231af35ee1831c599188d", - "zh:4d2b219d09abf3b1bb4df93d399ed156cadd61f44ad3baf5cf2954df2fba0831", - "zh:6130bdde527587bbe2dcaa7150363e96dbc5250ea20154176d82bc69df5d4ce3", - "zh:6cc326cd4000f724d3086ee05587e7710f032f94fc9af35e96a386a1c6f2214f", - "zh:78d5eefdd9e494defcb3c68d282b8f96630502cac21d1ea161f53cfe9bb483b3", - "zh:b6d88e1d28cf2dfa24e9fdcc3efc77adcdc1c3c3b5c7ce503a423efbdd6de57b", - "zh:ba74c592622ecbcef9dc2a4d81ed321c4e44cddf7da799faa324da9bf52a22b2", - "zh:c7c5cde98fe4ef1143bd1b3ec5dc04baf0d4cc3ca2c5c7d40d17c0e9b2076865", - "zh:dac4bad52c940cd0dfc27893507c1e92393846b024c5a9db159a93c534a3da03", - "zh:de8febe2a2acd9ac454b844a4106ed295ae9520ef54dc8ed2faf29f12716b602", - "zh:eab0d0495e7e711cca367f7d4df6e322e6c562fc52151ec931176115b83ed014", - ] -} - -provider "registry.terraform.io/hashicorp/tls" { - version = "4.0.4" - hashes = [ - "h1:GZcFizg5ZT2VrpwvxGBHQ/hO9r6g0vYdQqx3bFD3anY=", - "h1:Wd3RqmQW60k2QWPN4sK5CtjGuO1d+CRNXgC+D4rKtXc=", - "zh:23671ed83e1fcf79745534841e10291bbf34046b27d6e68a5d0aab77206f4a55", - "zh:45292421211ffd9e8e3eb3655677700e3c5047f71d8f7650d2ce30242335f848", - "zh:59fedb519f4433c0fdb1d58b27c210b27415fddd0cd73c5312530b4309c088be", - "zh:5a8eec2409a9ff7cd0758a9d818c74bcba92a240e6c5e54b99df68fff312bbd5", - "zh:5e6a4b39f3171f53292ab88058a59e64825f2b842760a4869e64dc1dc093d1fe", - "zh:810547d0bf9311d21c81cc306126d3547e7bd3f194fc295836acf164b9f8424e", - "zh:824a5f3617624243bed0259d7dd37d76017097dc3193dac669be342b90b2ab48", - "zh:9361ccc7048be5dcbc2fafe2d8216939765b3160bd52734f7a9fd917a39ecbd8", - "zh:aa02ea625aaf672e649296bce7580f62d724268189fe9ad7c1b36bb0fa12fa60", - "zh:c71b4cd40d6ec7815dfeefd57d88bc592c0c42f5e5858dcc88245d371b4b8b1e", - "zh:dabcd52f36b43d250a3d71ad7abfa07b5622c69068d989e60b79b2bb4f220316", - "zh:f569b65999264a9416862bca5cd2a6177d94ccb0424f3a4ef424428912b9cb3c", - ] -} - -provider "registry.terraform.io/linode/linode" { - version = "2.0.0" - hashes = [ - "h1:NLg13i6WnObZOznxKCn8/Y7mbSZRcTyAN3K8ilRTDPc=", - "zh:0c6e070a352f87d1e60fb1410808312de8e6065010811ffd7482558affef803d", - "zh:431477fb56989be089561bd8e0210ab7dabbc969a7fd3b8e72570c290b5bc911", - "zh:4e09042bddcbc5cf246d079e42da8b1d2ef353c37709a5f67ebe90d23192ff82", - "zh:4fbae3fa75e825649d007706b2d36460ae9c66fc8e18eb7012f526c9bcb2eeca", - "zh:6b734bf6ceca37b587080ec5e86c659d03e33af2db1557b35d8d667083d38e86", - "zh:78856cc4fb4422537580bca76278fb253cfc50d2ea3cc9bc1a3f9553663a85c6", - "zh:902b78e81a6d4f9e0c4cbd354895196dd143bb928c73da4522a323e16965d58a", - "zh:92001fbc49e80ee2bd4b8ab1cc7388dcbe1fc9ddf754754e5bdb37d1ee48bad7", - "zh:98f9e0ffba36b2acef28c3c2e02ff56806dc08ddcc8c6242e97fc740b8f8bc80", - "zh:ab902186e66cd3c1f27b6ffb870dd1361c4af1b26bf145b1ecb84281ed8f0d9a", - "zh:bb9640323bb08090bdf3d692c9f8d9580e31bf65ee80d183fa0ab0593bebefe1", - "zh:e60f92fb3a588bf118fecc8b96aeb8631b7664287257774cf5b77b97c5962a75", - "zh:eeb4822e840b3686334b62a808d5937ec6288bcf0c8c58e592f7097d2ce055c6", - "zh:f9bba3139aab1905666b455fae57406adcbaef2db62ce8be87c769d48140de42", - ] -} diff --git a/OWNERS.md b/OWNERS.md deleted file mode 100644 index 2854790..0000000 --- a/OWNERS.md +++ /dev/null @@ -1,8 +0,0 @@ -# Project Maintainers - - - [JR Morgan](https://github.com/liveaverage) - - [Cody Hill](https://github.com/c0dyhi11) - -# Project Contributors - - - [Contributions](https://github.com/equinix/terraform-metal-openshift-on-baremetal/graphs/contributors) diff --git a/main.tf b/main.tf index 94d61c3..d17393d 100644 --- a/main.tf +++ b/main.tf @@ -1,5 +1,5 @@ provider "equinix" { - auth_token = var.auth_token + auth_token = var.metal_auth_token } module "sshkey" { @@ -12,8 +12,8 @@ module "bastion" { source = "./modules/bastion" depends_on = [module.sshkey] - project_id = var.project_id - metro = var.metro + project_id = var.metal_project_id + metro = var.metal_metro plan = var.plan_bastion operating_system = var.bastion_operating_system ssh_private_key_path = module.sshkey.ssh_private_key_file @@ -60,9 +60,9 @@ module "openshift_bootstrap" { cluster_basedomain = var.cluster_basedomain node_count = var.count_bootstrap plan = var.plan_controlplane - metro = var.metro + metro = var.metal_metro ssh_private_key_path = module.sshkey.ssh_private_key_file - project_id = var.project_id + project_id = var.metal_project_id bastion_ip = module.bastion.lb_ip node_type = "bootstrap" depends = [module.prepare_openshift.finished] @@ -88,9 +88,9 @@ module "openshift_controlplane" { cluster_basedomain = var.cluster_basedomain node_count = var.count_controlplane plan = var.plan_controlplane - metro = var.metro + metro = var.metal_metro ssh_private_key_path = module.sshkey.ssh_private_key_file - project_id = var.project_id + project_id = var.metal_project_id bastion_ip = module.bastion.lb_ip node_type = "master" depends = [module.prepare_openshift.finished] @@ -116,9 +116,9 @@ module "openshift_workers" { cluster_basedomain = var.cluster_basedomain node_count = var.count_compute plan = var.plan_compute - metro = var.metro + metro = var.metal_metro ssh_private_key_path = module.sshkey.ssh_private_key_file - project_id = var.project_id + project_id = var.metal_project_id bastion_ip = module.bastion.lb_ip node_type = "worker" depends = [module.prepare_openshift.finished] @@ -156,11 +156,16 @@ module "openshift_install" { ocp_virtualization_enable = var.ocp_virtualization_enable } + resource "null_resource" "get_kubeconfig" { depends_on = [module.prepare_openshift.finished] provisioner "local-exec" { - command = "mkdir -p ${path.root}/auth; scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i ${module.sshkey.ssh_private_key_file} root@${module.bastion.lb_ip}:/tmp/artifacts/install/auth/* ${path.root}/auth/" + command = <