mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-11-30 16:36:50 -05:00
cli: write infrastructure to new state file (#2321)
Co-authored-by: 3u13r <lc@edgeless.systems>
This commit is contained in:
parent
8f5a2867b4
commit
322c4aad10
26 changed files with 263 additions and 109 deletions
|
|
@ -11,6 +11,7 @@ import (
|
|||
"io"
|
||||
"testing"
|
||||
|
||||
"github.com/edgelesssys/constellation/v2/cli/internal/state"
|
||||
"github.com/edgelesssys/constellation/v2/cli/internal/terraform"
|
||||
"github.com/edgelesssys/constellation/v2/internal/attestation/variant"
|
||||
"github.com/edgelesssys/constellation/v2/internal/cloud/cloudprovider"
|
||||
|
|
@ -31,7 +32,7 @@ type stubTerraformClient struct {
|
|||
iamOutput terraform.IAMOutput
|
||||
uid string
|
||||
attestationURL string
|
||||
applyOutput terraform.ApplyOutput
|
||||
infraState state.Infrastructure
|
||||
cleanUpWorkspaceCalled bool
|
||||
removeInstallerCalled bool
|
||||
destroyCalled bool
|
||||
|
|
@ -77,9 +78,9 @@ func (c *stubTerraformClient) RemoveInstaller() {
|
|||
c.removeInstallerCalled = true
|
||||
}
|
||||
|
||||
func (c *stubTerraformClient) ShowCluster(_ context.Context, _ cloudprovider.Provider) (terraform.ApplyOutput, error) {
|
||||
func (c *stubTerraformClient) ShowInfrastructure(_ context.Context, _ cloudprovider.Provider) (state.Infrastructure, error) {
|
||||
c.showCalled = true
|
||||
return c.applyOutput, c.showErr
|
||||
return c.infraState, c.showErr
|
||||
}
|
||||
|
||||
func (c *stubTerraformClient) ShowIAM(_ context.Context, _ cloudprovider.Provider) (terraform.IAMOutput, error) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue