terraform-provider-netlify
terraform-provider-netlify copied to clipboard
Support importing of sites
Importing of sites
I'm currently in the process of consolidating all of my online infrastructure into Terraform and would thus need to import my existing site into state.
Would this require special knowledge or is it I can contribute with some basic Go abilities?
You should be able to just run
terraform import netlify_site.my_website <api_id>
You can find api_id in
https://app.netlify.com/sites/my-website/settings/general
However there is a bug in the netlify go client and it can't import. https://github.com/netlify/open-api/pull/170 needs to be merged and the package updated in this repo to fix imports.
It looks like https://github.com/netlify/open-api/pull/200 and https://github.com/netlify/open-api/pull/164 have been merged. Possible to spin a 0.4.0 with these changes soon?
I hope for the 0.4.0 release. I just hit https://github.com/netlify/open-api/issues/162 same issue. Thanks!
There has been a release for the go client :) https://github.com/netlify/open-api/pull/170#issuecomment-566112522
Pinging @kmoe since that's the last person to have contributed to the repo. Would you be able to make a release with the new Netlify version?