layer0
layer0 copied to clipboard
Shelling out with terraform: provider "layer0" not available
When shelling out to terraform, it appears that the parent shell's is not completely inherited. This results in odd behavior such as the output below, when attempting to run system tests via make test
.
NOTE: A hacky solution is to make symlinks in every cases
directory to the terraform-provider-layer0
binary, but in the case of getent()
which is a function defined in the parent shell, it will not propagate to the shell created when shelling out.
NOTE #2: the issue with getent()
is worked around if you do not have a ~/.terraformrc
file.
go test -v -short -parallel 5 -timeout 15m
=== RUN TestDataSources
=== RUN TestDeadServiceRecreated
=== RUN TestEnvironmentLink
=== RUN TestImport
=== RUN TestServiceScale
=== RUN TestWindowsService
--- SKIP: TestWindowsService (0.00s)
windowsService_test.go:17: Skipping TestWindowsService in short mode
2018/04/24 11:45:13 endpoint: https://[REDACTED].us-east-1.elb.amazonaws.com
2018/04/24 11:45:13 token: [REDACTED]
2018/04/24 11:45:14 [ERROR] Error running [terraform init] from cases/datasources:
Initializing provider plugins...
- Checking for available provider plugins on https://releases.hashicorp.com...
Provider "layer0" not available for installation.
A provider named "layer0" could not be found in the official repository.