cloudfoundry / cf-deployment-concourse-tasks

Apache License 2.0
23 stars 75 forks source link

Fix: bbl-up task #155

Closed ctlong closed 1 year ago

ctlong commented 1 year ago

What is this change about?

Calls terraform init in bbl-up task if DELETE_TERRAFORM_PLUGINS is set to false. This should ensure that certain bbl commands, that require the correct plugins, work

Please provide contextual information.

https://github.com/cloudfoundry/bosh-bootloader/issues/560

Please check all that apply for this PR:

Did you update the README as appropriate for this change?

How should this change be described in release notes?

Fix issues related to running certain bbl commands by running terraform init beforehand.

What is the level of urgency for publishing this change?

Tag your pair, your PM, and/or team!

None

ctlong commented 1 year ago

This is a bit risky adding it straight to the setup_bosh_env_vars shared-function because we use it everywhere. I didn't want to track down all the places we need this terraform init though. If it's too much risk I could instead just add it to the generate-drats-config task in runtime-ci and we can add it more places wherever things break

Edit: changed the bbl-up task instead, which felt less risky and like a more long-lived solution.

ctlong commented 1 year ago

I want to try adding the correct providers to the .terraform folders first and see if that works

Edit: it worked

ctlong commented 1 year ago

We might be able to undo this change down the line once bbl cuts a new release that includes https://github.com/cloudfoundry/bosh-bootloader/pull/563.

There's no requirement that we do so, it should continue to work at that point. However, these plugin files are quite large, ~70MB, so it's not ideal to be uploading and downloading them all the time.