coreos / terraform-aws-kubernetes

Install a Kubernetes cluster the CoreOS Tectonic Way: HA, self-hosted, RBAC, etcd Operator, and more
Apache License 2.0
117 stars 67 forks source link

Running `terraform get` is bandwidth and disk intensive. #8

Closed bodgit closed 5 years ago

bodgit commented 7 years ago

As mentioned in #7, using this module and issuing a terraform get can take quite a long time to complete; this is due to there being multiple modules found within the https://github.com/coreos/tectonic-installer repository which is fairly large; Terraform isn't very intelligent here and will download a separate copy of the whole repository in order to fetch each referenced module.

From experience, it took ~ 15 minutes to complete and I ended up with this in my .terraform/modules/ directory after a terraform get:

$ du -csh  .terraform/modules/*
116M    .terraform/modules/0265c1acff7568f9479b3a4fa8cc6486
116M    .terraform/modules/3aa94b5df05f822eb0850160aed4b4c2
0       .terraform/modules/47e34766793267a2ca0c92b0125f9306
116M    .terraform/modules/4b606590b69ee3406e64b8eba3e06b93
116M    .terraform/modules/6295ae1cc6a065a11da6a34a40c5d60c
116M    .terraform/modules/67d8c51b048aaa7f7a915d2ad1b02350
116M    .terraform/modules/6e104386e328625fc55743e4c1d71da2
116M    .terraform/modules/6f0d7e10af33bc8da466f81c382c2b53
116M    .terraform/modules/7091451e1cb93545cf9c1a48bfb7bde8
116M    .terraform/modules/7e1bf06297d7ecd4edff2069216ad52b
116M    .terraform/modules/a6b15ed8796db8e41e9bd3a6e64ded13
116M    .terraform/modules/b566d7c9296e1b6728775296681fb99b
116M    .terraform/modules/c106d093c23885656fc1913c6af0379a
116M    .terraform/modules/c3319329e046819c25b064ff2d18bc05
116M    .terraform/modules/e21b76f292d0e58c18041364caacd7a6
116M    .terraform/modules/e4de431502698a9a78ee238d5736b454
116M    .terraform/modules/f27e913576b996172f07b8307378d99e
4.0K    .terraform/modules/module-subdir.json
1.9G    total

That's ~ 16 copies of the same repository and about 2 GB of data.