Giter Site home page Giter Site logo

Comments (4)

DGollings avatar DGollings commented on June 27, 2024 1

from lokomotive-kubernetes.

DGollings avatar DGollings commented on June 27, 2024 1

Just now deleted .terraform and the (remote) terraform.tfstate and it 'compiles' again, seems to be a temporary bug/feature due to a large? refactor.

Thanks, closing this issue

from lokomotive-kubernetes.

invidian avatar invidian commented on June 27, 2024

@DGollings thanks for reporting. maybe you can try removing . terraform directory and running terraform init again?

from lokomotive-kubernetes.

invidian avatar invidian commented on June 27, 2024

@DGollings I checked it and there is indeed an issue when updating to 2512344, I was able to reproduce it.

The problem is that template_dir resource from bootkube module holds the reference to the old path to bootkube module generated by Terraform via source_dir parameter. Then when planning, it tries to stat it and returns an error if the path does not exist anymore.

I'm not sure if that's the right approach yet, but it seems, that removing those resources from state and letting Terraform recreate them solves the issue:

$ terraform state list  | grep template_dir | grep bootkube
module.controller.module.bootkube.template_dir.bootstrap-manifests
module.controller.module.bootkube.template_dir.calico[0]
module.controller.module.bootkube.template_dir.kubelet
module.controller.module.bootkube.template_dir.kubernetes
$ terraform state rm module.controller.module.bootkube.template_dir.bootstrap-manifests module.controller.module.bootkube.template_dir.calico[0] module.controller.module.bootkube.template_dir.kubelet module.controller.module.bootkube.template_dir.kubernetes
Removed module.controller.module.bootkube.template_dir.kubernetes
Removed module.controller.module.bootkube.template_dir.kubelet
Removed module.controller.module.bootkube.template_dir.bootstrap-manifests
Removed module.controller.module.bootkube.template_dir.calico[0]
Successfully removed 4 resource instance(s).

You can try this out.

Another workaround would be to create a symlink to satisfy terraform_dir:

ln -s ./controller/bootkube .terraform/modules/controller.bootkube

Then run terraform apply, so template_dir resources can update their path.

from lokomotive-kubernetes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.