Skip to content

Commit

Permalink
MM-31627 - Support Operator Beta spec Custom Resource in Provisioner (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Szymongib authored Jan 19, 2021
1 parent bca3e68 commit 00e2317
Show file tree
Hide file tree
Showing 26 changed files with 812 additions and 307 deletions.
1 change: 1 addition & 0 deletions internal/api/installation.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ func handleCreateInstallation(c *Context, w http.ResponseWriter, r *http.Request
APISecurityLock: createInstallationRequest.APISecurityLock,
MattermostEnv: createInstallationRequest.MattermostEnv,
SingleTenantDatabaseConfig: createInstallationRequest.SingleTenantDatabaseConfig.ToDBConfig(createInstallationRequest.Database),
CRVersion: model.DefaultCRVersion,
State: model.InstallationStateCreationRequested,
}

Expand Down
2 changes: 2 additions & 0 deletions internal/api/installation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,7 @@ func TestCreateInstallation(t *testing.T) {
require.Equal(t, "dns.example.com", installation.DNS)
require.Equal(t, model.InstallationAffinityIsolated, installation.Affinity)
require.Equal(t, model.InstallationStateCreationRequested, installation.State)
require.Equal(t, model.DefaultCRVersion, installation.CRVersion)
require.Empty(t, installation.LockAcquiredBy)
require.EqualValues(t, 0, installation.LockAcquiredAt)
require.NotEqual(t, 0, installation.CreateAt)
Expand All @@ -437,6 +438,7 @@ func TestCreateInstallation(t *testing.T) {
require.Equal(t, "dns1.example.com", installation.DNS)
require.Equal(t, model.InstallationAffinityIsolated, installation.Affinity)
require.Equal(t, model.InstallationStateCreationRequested, installation.State)
require.Equal(t, model.DefaultCRVersion, installation.CRVersion)
require.Empty(t, installation.LockAcquiredBy)
require.EqualValues(t, 0, installation.LockAcquiredAt)
require.NotEqual(t, 0, installation.CreateAt)
Expand Down
20 changes: 9 additions & 11 deletions internal/mocks/model/installation_database.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

369 changes: 208 additions & 161 deletions internal/provisioner/kops_provisioner_cluster_installation.go

Large diffs are not rendered by default.

Loading

0 comments on commit 00e2317

Please sign in to comment.