-
Notifications
You must be signed in to change notification settings - Fork 9.8k
Added Terraform backend implementation for OCI Object Storage #36872
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
Conversation
db525f9
to
67fb650
Compare
|
40b679f
to
72406c9
Compare
4557056
to
ed9e8dc
Compare
ed9e8dc
to
dba0474
Compare
dba0474
to
347f16e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed & Approved
2dfb97c
to
388404f
Compare
388404f
to
d191460
Compare
d191460
to
6df0d1b
Compare
Hi @ravinitp, thanks for your PR! Could you please let us know when this PR is ready for review, and mark the PR as draft until then? Force pushes to this branch make it hard for us to identify what code has changed since the last time we took a look. |
@ravinitp Can you please run |
Co-authored-by: Radek Simko <radeksimko@users.noreply.github.com>
@SarahFrench This is Instanceprincipal auth log |
@radeksimko , ravbhart-mac:oci ravbhart$ go test -v ./
=== RUN TestBackendBasic
backend_test.go:29: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68010b5b"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
--- PASS: TestBackendBasic (16.90s)
=== RUN TestBackendLocked_ForceUnlock
backend_test.go:47: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68010b6c"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
backend_test.go:52: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68010b6c"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
testing.go:303: TestBackend: testing state locking for *oci.Backend
backend_test.go:61: TestBackend: testing state locking for *oci.Backend
testing.go:303: TestBackend: testing state locking for *oci.Backend
backend_test.go:63: TestBackend: testing state locking for *oci.Backend
--- PASS: TestBackendLocked_ForceUnlock (30.42s)
=== RUN TestBackendBasic_multipart_Upload
backend_test.go:75: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68010b8a"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
--- PASS: TestBackendBasic_multipart_Upload (19.35s)
=== RUN TestOCIBackendConfig_PrepareConfigValidation
=== RUN TestOCIBackendConfig_PrepareConfigValidation/null_bucket
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_trailing_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_double_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/workspace_key_prefix_with_leading_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/encryption_key_conflict
=== RUN TestOCIBackendConfig_PrepareConfigValidation/invalid_auth_method
=== RUN TestOCIBackendConfig_PrepareConfigValidation/empty_bucket
=== RUN TestOCIBackendConfig_PrepareConfigValidation/null_namespace
=== RUN TestOCIBackendConfig_PrepareConfigValidation/empty_namespace
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_leading_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/Invalid_encryption_key_combination
=== RUN TestOCIBackendConfig_PrepareConfigValidation/private_key_and_private_key_path_conflict
=== RUN TestOCIBackendConfig_PrepareConfigValidation/missing_region_for_InstancePrinciple_auth
--- PASS: TestOCIBackendConfig_PrepareConfigValidation (0.01s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/null_bucket (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_trailing_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_double_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/workspace_key_prefix_with_leading_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/encryption_key_conflict (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/invalid_auth_method (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/empty_bucket (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/null_namespace (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/empty_namespace (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_leading_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/Invalid_encryption_key_combination (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/private_key_and_private_key_path_conflict (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/missing_region_for_InstancePrinciple_auth (0.00s)
PASS
ok github.com/hashicorp/terraform/internal/backend/remote-state/oci 70.510s
ravbhart-mac:oci ravbhart$
|
@ravinitp I originally thought the dependency change in the With that in mind, can you please run |
@ravinitp As per CI failure - Can you also run the following command and commit & push the outcome, please?
|
Done goimports and sync deps ravbhart-mac:oci ravbhart$ go test -v ./
=== RUN TestBackendBasic
backend_test.go:30: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68012121"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
--- PASS: TestBackendBasic (15.57s)
=== RUN TestBackendLocked_ForceUnlock
backend_test.go:48: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68012131"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
backend_test.go:53: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-68012131"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
testing.go:303: TestBackend: testing state locking for *oci.Backend
backend_test.go:62: TestBackend: testing state locking for *oci.Backend
testing.go:303: TestBackend: testing state locking for *oci.Backend
backend_test.go:64: TestBackend: testing state locking for *oci.Backend
--- PASS: TestBackendLocked_ForceUnlock (29.58s)
=== RUN TestBackendBasic_multipart_Upload
backend_test.go:76: TestBackendConfig on *oci.Backend with configtesting.synthBody{Filename:"<TestWrapConfig>", Values:map[string]cty.Value{"bucket":cty.StringVal("terraform-remote-oci-test-6801214e"), "key":cty.StringVal("testState.json"), "namespace":cty.StringVal("idxvx0yktto5")}}
--- PASS: TestBackendBasic_multipart_Upload (19.15s)
=== RUN TestOCIBackendConfig_PrepareConfigValidation
=== RUN TestOCIBackendConfig_PrepareConfigValidation/null_bucket
=== RUN TestOCIBackendConfig_PrepareConfigValidation/null_namespace
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_double_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/workspace_key_prefix_with_leading_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/encryption_key_conflict
=== RUN TestOCIBackendConfig_PrepareConfigValidation/Invalid_encryption_key_combination
=== RUN TestOCIBackendConfig_PrepareConfigValidation/private_key_and_private_key_path_conflict
=== RUN TestOCIBackendConfig_PrepareConfigValidation/invalid_auth_method
=== RUN TestOCIBackendConfig_PrepareConfigValidation/empty_bucket
=== RUN TestOCIBackendConfig_PrepareConfigValidation/empty_namespace
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_leading_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/key_with_trailing_slash
=== RUN TestOCIBackendConfig_PrepareConfigValidation/missing_region_for_InstancePrinciple_auth
--- PASS: TestOCIBackendConfig_PrepareConfigValidation (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/null_bucket (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/null_namespace (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_double_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/workspace_key_prefix_with_leading_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/encryption_key_conflict (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/Invalid_encryption_key_combination (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/private_key_and_private_key_path_conflict (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/invalid_auth_method (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/empty_bucket (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/empty_namespace (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_leading_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/key_with_trailing_slash (0.00s)
--- PASS: TestOCIBackendConfig_PrepareConfigValidation/missing_region_for_InstancePrinciple_auth (0.00s)
PASS
ok github.com/hashicorp/terraform/internal/backend/remote-state/oci 65.652s
ravbhart-mac:oci ravbhart$ |
Co-authored-by: Radek Simko <radeksimko@users.noreply.github.com>
Thanks for raising this! Given that the provider is already named |
Terraform backend implementation for OCI Object Storage
A new Terraform backend utilising Oracle Cloud Infrastructure (OCI) Object Storage as the storage backend. Leveraging OCI Object Storage provides a scalable and cost-effective alternative to traditional backends, offering a robust solution for state file storage and management.
RFC#34465
RFC#32634
Added
Terraform backend implementation for OCI Object Storage
Target Release
1.12.x
CHANGELOG entry