-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix tests and don't offer a specific remote backend #48
Conversation
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
@jmarhee What is the I do see a few other null_resource.controller* resources, perhaps this reference should be using one of those? |
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
The We also seem to be missing ExternalNetwork.sh (#37). I got a little further locally by deleting that file and removing the NovaConsole My provision eventually failed because I didn't create the metal-key file with the expected params. I've created #49 as a way to prevent that in the future. |
The ExternalNetworks.tf was one of the files suffixed with The resource in NovaConsole should read |
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
https://www.terraform.io/docs/configuration/dependency-lock.html#lock-file-location > You should include this file in your version control repository so that you > can discuss potential changes to your external dependencies via code review, > just as you would discuss potential changes to your configuration itself. Signed-off-by: Marques Johansson <mjohansson@equinix.com>
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
@jmarhee I've included changes to remove those files. The plan tests are currently failing because this project is not configured with an EM API token for testing. I thought it might pull this from state using the TF_API token, but that is not the case (perhaps because I renamed the variable, or perhaps because variables are not pulled from backends). We'll need a service token of sorts, a user token from a user account dedicated to this work that we can configure here. This will need to be defined as I do think we'll need to address #49 too, but we can address that in a separate issue once we see that the plan and apply is working (which it does from my local testing of this branch). |
Signed-off-by: Marques Johansson <mjohansson@equinix.com>
If this project can get by with a project token, we could try this: https://github.com/displague/metal-actions-example It would generate a project id/name/token/ssh key for our testing and destroy it when done. We could use the same projectName on each build so we don't get excessive build failure devices. Instead we will end up with tests getting stuck until the known projectName is manually deleted. The sweeper could run first (if it is taught how to delete projects by name rather than id alone). |
Looks good. I think we can proceed. |
Fixes #45
Fixes #47
The
main.tf
file was converted tobackends.hcl
format (https://www.terraform.io/docs/backends/types/remote.html#using-cli-input) and moved into aBACKEND_FILE
secret in GH Actions