Skip to content

Instantly share code, notes, and snippets.

@chanwit
Last active January 11, 2022 15:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chanwit/9ba9b8640c58a32a290e6a1f16e0e715 to your computer and use it in GitHub Desktop.
Save chanwit/9ba9b8640c58a32a290e6a1f16e0e715 to your computer and use it in GitHub Desktop.
infrav1.Terraform{
ObjectMeta: metav1.ObjectMeta{
Name: terraformName,
Namespace: "flux-system",
},
Spec: infrav1.TerraformSpec{
ApprovePlan: "auto",
Path: "./terraform-hello-world-example",
SourceRef: infrav1.CrossNamespaceSourceReference{
Kind: "GitRepository",
Name: sourceName,
Namespace: "flux-system",
},
},
}
g.Eventually(func() []string {
err := k8sClient.Get(ctx, helloWorldTFKey, &createdHelloWorldTF)
if err != nil {
return nil
}
return createdHelloWorldTF.Status.AvailableOutputs
}, timeout, interval).Should(Equal([]string{"hello_world"}))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment