fix: refactor postgres after api updates
Some checks failed
CI Workflow / Check GoReleaser config (pull_request) Successful in 12s
CI Workflow / CI (pull_request) Failing after 30s
Publish / Check GoReleaser config (pull_request) Has been skipped
CI Workflow / Code coverage report (pull_request) Has been skipped
Publish / Publish provider (pull_request) Has been skipped
Some checks failed
CI Workflow / Check GoReleaser config (pull_request) Successful in 12s
CI Workflow / CI (pull_request) Failing after 30s
Publish / Check GoReleaser config (pull_request) Has been skipped
CI Workflow / Code coverage report (pull_request) Has been skipped
Publish / Publish provider (pull_request) Has been skipped
This commit is contained in:
parent
32b83a0836
commit
764978db88
6 changed files with 52 additions and 16 deletions
|
|
@ -261,13 +261,11 @@ func modelToCreateInstancePayload(netAcl []string, model postgresflexalpha.Insta
|
|||
Encryption: &enc,
|
||||
FlavorId: model.FlavorId.ValueStringPointer(),
|
||||
Name: model.Name.ValueStringPointer(),
|
||||
Network: &postgresflex.InstanceNetwork{
|
||||
Network: &postgresflex.InstanceNetworkCreate{
|
||||
AccessScope: postgresflex.InstanceNetworkGetAccessScopeAttributeType(
|
||||
model.Network.AccessScope.ValueStringPointer(),
|
||||
),
|
||||
Acl: &netAcl,
|
||||
InstanceAddress: model.Network.InstanceAddress.ValueStringPointer(),
|
||||
RouterAddress: model.Network.RouterAddress.ValueStringPointer(),
|
||||
Acl: &netAcl,
|
||||
},
|
||||
Replicas: postgresflex.CreateInstanceRequestPayloadGetReplicasAttributeType(&replVal),
|
||||
RetentionDays: model.RetentionDays.ValueInt64Pointer(),
|
||||
|
|
@ -452,10 +450,7 @@ func (r *instanceResource) Update(ctx context.Context, req resource.UpdateReques
|
|||
BackupSchedule: model.BackupSchedule.ValueStringPointer(),
|
||||
FlavorId: model.FlavorId.ValueStringPointer(),
|
||||
Name: model.Name.ValueStringPointer(),
|
||||
Network: &postgresflex.InstanceNetwork{
|
||||
AccessScope: postgresflex.InstanceNetworkGetAccessScopeAttributeType(
|
||||
model.Network.AccessScope.ValueStringPointer(),
|
||||
),
|
||||
Network: &postgresflex.InstanceNetworkUpdate{
|
||||
Acl: &netAcl,
|
||||
},
|
||||
Replicas: postgresflex.UpdateInstanceRequestPayloadGetReplicasAttributeType(&replInt32),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue