coreos / tectonic-docs

Tectonic documentation - https://coreos.com/tectonic/docs/latest/
Apache License 2.0
42 stars 48 forks source link

Azure documentation is not correct regarding terraform #68

Open jolcese opened 6 years ago

jolcese commented 6 years ago

I've been trying to install Tectonic on Azure and it's not working if I follow the instructions. I've used both MacOS and Ubuntu with identical results and I'm using the proper terreform

The following step is failing:

jolcese@jolcese-osx:~/src/kubernetes/tectonic$ which terraform
/Users/jolcese/src/kubernetes/tectonic/tectonic-installer/darwin/terraform
jolcese@jolcese-osx:~/src/kubernetes/tectonic$ terraform init platforms/azure
Initializing configuration from: "platforms/azure"...
Error copying source: The destination path contains Terraform configuration files. The init command
with a SOURCE parameter can only be used on a directory without existing
Terraform files.

Please resolve this issue and try again.
jolcese@jolcese-osx:~/src/kubernetes/tectonic$

But this one works:

jolcese@jolcese-osx:~/src/kubernetes/tectonic$ cd platforms/azure/
jolcese@jolcese-osx:~/src/kubernetes/tectonic/platforms/azure$
jolcese@jolcese-osx:~/src/kubernetes/tectonic/platforms/azure$ terraform init
Downloading modules (if any)...
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/resource-group
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/vnet
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/etcd
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/master-as
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/worker-as
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/dns/azure
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/bootkube
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/tectonic
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/net/flannel-vxlan
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/net/calico-network-policy
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/net/ignition
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/udev-rules
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/net/ignition
Get: file:///Users/jolcese/src/kubernetes/tectonic/modules/azure/udev-rules

Terraform has been successfully initialized!

You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.

If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your environment. If you forget, other
commands will detect it and remind you to do so if necessary.
jolcese@jolcese-osx:~/src/kubernetes/tectonic/platforms/azure$

And then, the plan \ apply shall be executed from:

jolcese@jolcese-osx:~/src/kubernetes/tectonic/platforms/azure$ terraform plan -var-file=../../build/${CLUSTER}/terraform.tfvars
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.

data.template_file.tectonic_rkt: Refreshing state...
data.ignition_systemd_unit.locksmithd: Refreshing state...
data.ignition_user.core: Refreshing state...
data.template_file.tectonic: Refreshing state...
data.ignition_user.core: Refreshing state...
data.ignition_file.azure_udev_rules: Refreshing state...
data.template_file.kubelet-worker: Refreshing state...
data.template_file.bootkube_service: Refreshing state...
data.template_file.tectonic_service: Refreshing state...
data.ignition_systemd_unit.docker: Refreshing state...
data.ignition_file.kubelet_env: Refreshing state...
...
...
...
Plan: 144 to add, 0 to change, 0 to destroy.
jolcese@jolcese-osx:~/src/kubernetes/tectonic/platforms/azure$
duckty commented 5 years ago

This issue is happening with tectonic_1.9.6-tectonic.2


cd ~/Downloads/tectonic_1.9.6-tectonic.2
/usr/local/bin/terraform init

Initializing provider plugins...
- Checking for available provider plugins on https://releases.hashicorp.com...
- Downloading plugin for provider "template" (1.0.0)...
- Downloading plugin for provider "tls" (1.0.0)...
- Downloading plugin for provider "archive" (1.0.0)...
- Downloading plugin for provider "external" (1.0.0)...
- Downloading plugin for provider "ignition" (1.0.0)...
- Downloading plugin for provider "local" (1.0.0)...
- Downloading plugin for provider "null" (1.0.0)...
- Downloading plugin for provider "random" (1.0.0)...

Terraform has been successfully initialized!

You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.

If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your working directory. If you forget, other
commands will detect it and remind you to do so if necessary.

/usr/local/bin/terraform plan -var-file=build/${CLUSTER}/terraform.tfvars platforms/azure

Error: Error loading modules: module bootstrapper: not found, may need to run 'terraform init'```