Skip to the content.

Object Storage

Module: services/storage · Image: nebius-mocker-storage · NEBIUS_MOCKER_SERVICES=storage M1 tier: T2 bucket, inventory, transfer · M3: T3 S3 data plane · Endpoints: cpl.storage, transfer.storage

Implementation status

Piece Status
nebius.storage.v1.BucketService: Get, GetByName, List (paged), ListWithFilter, Create, Update (reset mask, resource_version), Delete (soft, purge_at/ttl), Purge, Undelete ✅ T2
Bucket semantics: global S3 names, naming rules, IMMUTABLE_NAME, versioning_policy default + transition rules, status.state/domain_name/region/bucket_type, soft delete with deleted_at/purge_at, background purge sweeper ✅
status.counters: per storage class, current/noncurrent simple and multipart objects, multipart uploads and in-flight parts, computed from the object store on every read ✅
spec.max_size_bytes: writes that would exceed it are refused at the S3 front (QuotaExceeded) ✅
Quotas storage.bucket.count (every bucket type, gRPC and S3 CreateBucket) and storage.transfer.count (v1 and v1alpha1; checked when the transfer is stored, so a refused transfer fails its operation) (quotas.md) ✅ contract: test/contract/quotas_areas_test.go
Object size quotas (storage.bucket.size.<class>) Not yet
spec.cors: preflight OPTIONS and Access-Control-* headers at the S3 front ✅
spec.bucket_policy: group and anonymous rules, storage.* roles, path patterns, evaluated at the S3 front; status.anonymous_access_enabled ✅
spec.lifecycle_configuration: expiration (days/date), expired delete markers, noncurrent expiration (+ newer_noncurrent_versions), abort incomplete multipart uploads, with prefix/size/tag filters, applied on the mock clock ✅
spec.default_storage_class, spec.force_storage_class: STANDARD and ENHANCED_THROUGHPUT ✅
Lifecycle transitions (transition, noncurrent_version_transition), last_access_filter, spec.last_access, storage class INTELLIGENT ❌ rejected with INVALID_ARGUMENT naming the field (see below)
Backing buckets in RustFS (created, versioned, force-deleted with all versions on purge) ✅
S3 data plane: S3 front on :4580, SigV4 with Nebius access keys (credential-scope region checked), anonymous requests for policy grants, IAM-authorized, relayed to RustFS ✅ (NEBIUS_MOCKER_OBJSTORE=rustfs)
S3 bucket calls: CreateBucket (aws s3 mb), DeleteBucket (aws s3 rb), Get/Put/Delete BucketLifecycleConfiguration, Get/Put/Delete BucketCors, Get/PutBucketVersioning, GetBucketLocation, on the Nebius bucket records ✅
nebius_storage_v1_bucket resource + data source with the official provider (incl. cors, bucket_policy, lifecycle, max_size_bytes; counters through the data source) ✅ e2e: test/terraform/storage (make e2e, make e2e-storage)
Objects with the unmodified hashicorp/aws provider (aws_s3_object + data source) against the S3 front ✅ e2e: test/terraform/storage (make e2e-storage)
Go SDK: buckets with gosdk, objects with the AWS SDK for Go v2 ✅ e2e: test/storage (make e2e-storage)
Documented CLI flows: nebius storage bucket …, the quick start (nebius iam … service account + access key, aws configure set …, aws s3 mb/cp/ls/sync/mv/rm/rb, aws s3api put/get-bucket-lifecycle-configuration) ✅ e2e: test/storage/cli_e2e_test.go (make e2e-storage; pinned CLIs installed into the user cache, never system-wide)
Filesystem buckets (spec.filesystem_bucket): a view of a compute shared filesystem (READY, same project, compute.filesystems.useViaObjectStorage on it; recorded on the filesystem atomically with its checks, so the filesystem cannot be deleted while the bucket exists); status.bucket_type FILESYSTEM; objects relayed to the filesystem’s store bucket with the filesystem size as capacity; FILESYSTEM storage class; immediate delete that keeps the files; ListWithFilter by type and filesystem_id. Refused by name: non-root directory, non-default uid/gid/file_mode/directory_mode, versioning, lifecycle rules, anonymous policies, delayed deletion, S3 PutBucketVersioning/PutBucketLifecycleConfiguration/object tagging (501) ✅ e2e: test/filesystems (make e2e-filesystems), test/terraform/compute/filesystem_test.go. See compute.md
nebius.storage.v1.InventoryService: Get, GetByName, List (paged), Create, Update (reset mask, resource_version), Delete; up to 5 per bucket, name per bucket and immutable, destination permission check ✅ T2
Inventory reports: AWS-compatible CSV (gzip) and Parquet (Snappy) files, manifest.json, manifest.checksum and the Hive symlink.txt written into the destination bucket, first report at the next sweep then daily/weekly on the mock clock; all optional fields (last access tracked by the S3 front, checksums, multipart flag, lifecycle expiration, tags); status.last_success / error_code (DESTINATION_BUCKET_NOT_FOUND, PERMISSION_DENIED, QUOTA_EXCEEDED) ✅ e2e: test/storage/inventory_e2e_test.go (make e2e-storage)
nebius.storage.v1.TransferService: Get, GetByName, List (paged), Create, Update (reset mask; immutables refused by name; input-only secrets kept when sent back empty), Stop, Resume, Delete (resource_version), GetIterationHistory ✅ T2
nebius.storage.v1alpha1.TransferService (deprecated): every RPC; its transfers are also visible and controllable through v1 ✅ T2
Transfer iterations really copy objects: sources nebius (buckets of this mocker, through its S3 front with the given access key), s3_compatible (any S3 endpoint) and azure_blob_storage; destinations nebius and s3_compatible; prefixes, IF_NEWER/NEVER (v1alpha1 also ALWAYS), touch_unmanaged, enable_deletes_in_destination, metadata-only updates, multipart from 100 MB, the three stop conditions, inter_iteration_interval and both limiters, all on the mock clock ✅ e2e: test/storage/transfer_e2e_test.go (make e2e-storage, with a second RustFS as external S3 and Azurite as Azure)
nebius_storage_v1_inventory, nebius_storage_v1_transfer, nebius_storage_v1alpha1_transfer resources + data sources with the official provider (incl. write-only sensitive secrets) ✅ e2e: test/terraform/storage/{inventory,transfer}_test.go (make e2e)
Documented CLI flows: nebius storage inventory create/list/get-by-name/update/delete, nebius storage transfer create --file/list/get/update/stop/resume/get-iteration-history/delete, nebius storage v1alpha1 transfer …, reports read with aws s3 ls/cp ✅ e2e: test/storage/{inventory,transfer}_cli_e2e_test.go (make e2e-storage)
S3 front keeps client checksums (x-amz-checksum-* headers and aws-chunked trailers, whose signature is verified) and returns them with ChecksumMode ✅ e2e: services/storage/s3/checksum_e2e_test.go

Verified against: nebius/api@4522189, terraform-provider-nebius v0.6.91, gosdk v0.2.100 (hashicorp/aws 6.70.0, RustFS 1.0.6, Azurite 3.35.0, nebius CLI 0.12.312, AWS CLI 2.42.3); inventory and transfer services added 2026-11-26.

Covered by domain unit tests with fakes (services/storage/domain: policy, CORS, lifecycle executor, counters, storage classes, S3 bucket calls, inventory validation/scheduler/report formats, transfer validation/state machine/runner and the iteration engine with its limiters), adapter tests (services/storage/backend/{s3endpoint,azblob} against RustFS and Azurite), DAL tests (services/storage/dal), S3 front tests (services/storage/s3: routing, SigV4 accept/reject incl. region, XML conversion), pkg/sigv4 and pkg/objstore (inventory conformance) tests, gosdk contract tests on the in-memory object store (test/contract/storage_bucket_test.go), and the Docker-gated suites above (make e2e-storage starts and removes RustFS).

Overview

S3-compatible object storage. The gRPC API manages the control plane: buckets (versioning, lifecycle rules, CORS, policies, storage classes, size limits, filesystem-bucket mode), inventories (scheduled object listings) and transfers (copying from external S3-compatible sources into a bucket). Object reads and writes go through the S3 HTTP API, which is not part of nebius/api.

Resource kind Message NID prefix Parent States
Bucket Bucket storagebucket project CREATING, ACTIVE, UPDATING, SCHEDULED_FOR_DELETION
Inventory Inventory storagebucketinventory bucket  
Transfer Transfer (v1, v1alpha1) storagetransfer project ACTIVE, STOPPING, STOPPED, FAILED, DELETING; iteration history

Emulation design

NebiusMocker implements no object storage. Object bytes live in RustFS (rustfs/rustfs:1.0.6, multi-arch), reached through the shared pkg/objstore port (Store plus Inventory: versions, multipart uploads, tags). NebiusMocker provides the Nebius-shaped wrapping: the gRPC control plane, authentication and authorization, and every bucket setting that RustFS cannot apply with Nebius semantics.

terraform / gosdk / nebius CLI ──gRPC :4566──▶ BucketService ──▶ dal (pkg/store: bucket metadata, global name index)
                                                   └──────────▶ pkg/objstore (RustFS): ensure / versioning / force-delete,
                                                                inventory for status.counters and lifecycle rules

aws CLI / AWS SDK / hashicorp/aws / browsers ──S3 HTTP :4580──▶ services/storage/s3 (S3 front)
   0. OPTIONS: CORS preflight from spec.cors (no authentication)
   1. SigV4 verify (pkg/sigv4): credential-scope region must be the bucket region; secret of the iam.v2 AccessKey
      (peer.AccessKeys, provided by IAM). Unsigned requests are anonymous.
   2. domain.S3Gate: bucket must be an ACTIVE Nebius bucket; allowed by an IAM permit of the key's service account,
      or by a spec.bucket_policy rule (group via peer.GroupMembers, or anonymous)
   3. bucket calls (mb/rb, versioning, lifecycle, CORS, location) → the Nebius bucket record
   4. object calls: storage class and max_size_bytes applied, relayed path-style to RustFS re-signed with the RustFS
      credentials (pkg/objstore/rustfs.Forwarder); responses get CORS headers and Nebius storage-class names

Bucket settings

Every BucketSpec field either has its Nebius effect or is rejected with INVALID_ARGUMENT naming the field. Nothing is stored without effect.

Inventories

An inventory (storagebucketinventory, child of its source bucket) makes the mocker write periodic object listings of the bucket into a destination bucket, as docs.nebius.com/object-storage/buckets/inventory describes. Reports are written by the storage module’s minute sweeper (mock clock) into the object store; read them like any object, through the S3 front (aws s3 ls/cp, the AWS SDK).

Transfers

A transfer (storagetransfer, child of a project) copies objects in iterations, as docs.nebius.com/object-storage/transfer describes. The mocker’s engine talks real S3 (AWS SDK for Go) or Azure Blob (Azure SDK) to both sides with the credentials of the spec. A nebius side is a bucket of this mocker, reached through its own S3 front, so SigV4, IAM permits, bucket policies, size limits and audit apply exactly as for any client. Iterations run in the background on the mock clock.

Not yet

Terraform

Kind Terraform type Service RPCs called Tier
Resource nebius_storage_v1_bucket nebius.storage.v1.BucketService Get, GetByName, Create, Update, Delete + OperationService.Get T2
Resource nebius_storage_v1_inventory nebius.storage.v1.InventoryService Get, GetByName, Create, Update, Delete + OperationService.Get T2
Resource nebius_storage_v1_transfer nebius.storage.v1.TransferService Get, GetByName, Create, Update, Delete + OperationService.Get T2
Resource nebius_storage_v1alpha1_transfer nebius.storage.v1alpha1.TransferService Get, GetByName, Create, Update, Delete + OperationService.Get T2
Data source nebius_storage_v1_bucket nebius.storage.v1.BucketService Get, GetByName T2
Data source nebius_storage_v1_inventory nebius.storage.v1.InventoryService Get, GetByName T2
Data source nebius_storage_v1_transfer nebius.storage.v1.TransferService Get, GetByName T2
Data source nebius_storage_v1alpha1_transfer nebius.storage.v1alpha1.TransferService Get, GetByName T2

Objects are managed the way Nebius documents for S3 tools: the official hashicorp/aws provider with the S3 endpoint, region and an access key, here the mocker’s S3 front:

ephemeral "nebius_iam_v2_access_key_secret" "s3" {
  id = nebius_iam_v2_access_key.s3.id           # or the key's ID from another config
}

provider "aws" {
  region     = "eu-north1"
  access_key = ephemeral.nebius_iam_v2_access_key_secret.s3.aws_access_key_id
  secret_key = ephemeral.nebius_iam_v2_access_key_secret.s3.secret
  endpoints { s3 = "http://127.0.0.1:4580" }    # Nebius: https://storage.<region>.nebius.cloud
  s3_use_path_style           = true
  skip_credentials_validation = true
  skip_region_validation      = true
  skip_requesting_account_id  = true
  skip_metadata_api_check     = true
}

resource "aws_s3_object" "hello" {
  bucket  = nebius_storage_v1_bucket.data.name
  key     = "hello.txt"
  content = "hello"
}

Configuration

Env Default Description
NEBIUS_MOCKER_OBJSTORE memory Object store shared by modules: memory (no S3 data plane) or rustfs
NEBIUS_MOCKER_OBJSTORE_ENDPOINT http://127.0.0.1:9000 RustFS S3 endpoint
NEBIUS_MOCKER_OBJSTORE_ACCESS_KEY / _SECRET_KEY rustfsadmin / rustfsadmin RustFS credentials (never exposed to users)
NEBIUS_MOCKER_OBJSTORE_REGION us-east-1 Region the mocker signs RustFS requests for
NEBIUS_MOCKER_STORAGE_S3_LISTEN :4580 S3 front address; off disables it
NEBIUS_MOCKER_STORAGE_S3_DOMAIN storage.eu-north1.mocker.localhost S3 host; status.domain_name = <bucket>.<domain>
NEBIUS_MOCKER_STORAGE_REGION eu-north1 status.region and GetBucketLocation
NEBIUS_MOCKER_STORAGE_PURGE_GRACE 168h Default soft-delete grace

Open questions

API surface

nebius.storage.v1.BucketService

Endpoint: cpl.storage.api.nebius.cloud:443 · Proto: nebius/storage/v1/bucket_service.proto · used by Terraform

RPC Request Response TF
Get GetBucketRequest Bucket ✅
GetByName GetBucketByNameRequest Bucket ✅
List ListBucketsRequest ListBucketsResponse  
ListWithFilter ListBucketsWithFilterRequest ListBucketsWithFilterResponse  
Create CreateBucketRequest common.v1.Operation ✅
Update UpdateBucketRequest common.v1.Operation ✅
Delete DeleteBucketRequest common.v1.Operation ✅
Purge PurgeBucketRequest common.v1.Operation  
Undelete UndeleteBucketRequest common.v1.Operation  

nebius.storage.v1.InventoryService

Endpoint: cpl.storage.api.nebius.cloud:443 · Proto: nebius/storage/v1/inventory_service.proto · used by Terraform

RPC Request Response TF
Get GetInventoryRequest Inventory ✅
GetByName common.v1.GetByNameRequest Inventory ✅
List ListInventoriesRequest ListInventoriesResponse  
Create CreateInventoryRequest common.v1.Operation ✅
Update UpdateInventoryRequest common.v1.Operation ✅
Delete DeleteInventoryRequest common.v1.Operation ✅

nebius.storage.v1.TransferService

Endpoint: transfer.storage.api.nebius.cloud:443 · Proto: nebius/storage/v1/transfer_service.proto · used by Terraform

RPC Request Response TF
Get GetTransferRequest Transfer ✅
GetByName common.v1.GetByNameRequest Transfer ✅
List ListTransfersRequest ListTransfersResponse  
Create CreateTransferRequest common.v1.Operation ✅
Update UpdateTransferRequest common.v1.Operation ✅
Stop StopTransferRequest common.v1.Operation  
Resume ResumeTransferRequest common.v1.Operation  
Delete DeleteTransferRequest common.v1.Operation ✅
GetIterationHistory GetIterationHistoryRequest GetIterationHistoryResponse  

nebius.storage.v1alpha1.TransferService (deprecated)

Endpoint: transfer.storage.api.nebius.cloud:443 · Proto: nebius/storage/v1alpha1/transfer_service.proto · used by Terraform

RPC Request Response TF
Get GetTransferRequest Transfer ✅
GetByName common.v1.GetByNameRequest Transfer ✅
List ListTransfersRequest ListTransfersResponse  
Create CreateTransferRequest common.v1.Operation ✅
Update UpdateTransferRequest common.v1.Operation ✅
Stop StopTransferRequest common.v1.Operation  
Resume ResumeTransferRequest common.v1.Operation  
Delete DeleteTransferRequest common.v1.Operation ✅
GetIterationHistory GetIterationHistoryRequest GetIterationHistoryResponse