Data

Object storage

S3-compatible buckets for uploads, exports, and generated files. Each bucket has its own key, and your app is configured the moment it’s ready.

Create a bucket

Terminal
apprail buckets create shop uploads --quota 10
apprail buckets shop

The quota is 1–100 GB (10 by default); an upload that would go past it is refused. Bucket names only need to be unique within your environment.

Use it from your app

The environment’s default bucket sets the variables most S3 libraries read on their own:

VariableValue
S3_BUCKETThe bucket’s name on the server
S3_ENDPOINT, AWS_ENDPOINT_URL_S3The private S3 endpoint
S3_REGION, AWS_REGIONThe region name to sign requests with
AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEYA key for this bucket only
S3_FORCE_PATH_STYLEtrue

Every bucket also gets APPRAIL_BUCKET_<NAME>_ENDPOINT, _NAME, _REGION, _ACCESS_KEY_ID, and _SECRET_ACCESS_KEY.

// Node.js (AWS SDK v3)
const s3 = new S3Client({ forcePathStyle: true }); // endpoint, region, and key come from the environment
await s3.send(new PutObjectCommand({ Bucket: process.env.S3_BUCKET, Key: "avatars/42.png", Body: file }));

Use path-style requests (forcePathStyle: true, or S3_FORCE_PATH_STYLE). The endpoint is private to your environment, so browsers can’t reach it directly: serve files through your app, or have your app stream uploads and downloads.

Keys, deletion, and copies

Not available yet: public or website buckets, versioning, lifecycle rules, and browser-facing presigned URLs.

Take your files with you

Any S3 tool works with the bucket’s credentials from inside the environment, for example with apprail run and aws s3 sync to another provider.