CLI
Storage commands
Manage S3-compatible object storage with familiar commands.
On this page8 sections
Buckets#
List buckets#
Text
$ edge storage list
NAME OBJECTS SIZE CREATED
my-assets 1,234 2.3 GB 2025-01-15
backups 456 45.6 GB 2025-02-01
website-static 89 123 MB 2025-02-10Create a bucket#
Text
$ edge storage create my-new-bucket
Creating bucket... done
Name: my-new-bucket
Region: londonDelete a bucket#
Terminal
# Delete empty bucket
edge storage delete my-bucket
# Delete bucket and all contents
edge storage delete my-bucket --forceBucket info#
Text
$ edge storage info my-assets
Name: my-assets
Region: london
Objects: 1,234
Size: 2.3 GB
Created: 2025-01-15Objects#
List objects#
Text
$ edge storage ls my-bucket
NAME SIZE MODIFIED
images/ - -
documents/ - -
index.html 4.2 KB 2025-02-10 14:30
styles.css 12.3 KB 2025-02-10 14:30
app.js 45.6 KB 2025-02-10 14:32
# List contents of a folder
$ edge storage ls my-bucket/images/
NAME SIZE MODIFIED
logo.png 23.4 KB 2025-02-08
hero.jpg 1.2 MB 2025-02-08
icons/ - -
# List all objects recursively (note: -R uppercase)
$ edge storage ls my-bucket -RUpload files#
Terminal
# Upload a single file
edge storage cp ./logo.png my-bucket/images/
# Upload to specific path
edge storage cp ./file.pdf my-bucket/documents/report.pdf
# Upload multiple files
edge storage cp ./dist/* my-bucket/static/
# Recursive upload (folder, note: -R uppercase)
edge storage cp -R ./public my-bucket/website/Download files#
Terminal
# Download a single file
edge storage cp my-bucket/images/logo.png ./downloads/
# Download to specific path
edge storage cp my-bucket/report.pdf ./local-report.pdf
# Recursive download (folder, note: -R uppercase)
edge storage cp -R my-bucket/backups/ ./local-backups/Delete objects#
Terminal
# Delete a single object
edge storage rm my-bucket/old-file.txt
# Delete multiple objects
edge storage rm my-bucket/file1.txt my-bucket/file2.txt
# Recursive delete (folder, note: -R uppercase)
edge storage rm -R my-bucket/old-folder/
# Delete without confirmation
edge storage rm -R my-bucket/temp/ --forceMove or rename#
Terminal
# Rename an object
edge storage mv my-bucket/old-name.txt my-bucket/new-name.txt
# Move to different folder
edge storage mv my-bucket/file.txt my-bucket/archive/file.txtSync#
Synchronise directories between your local filesystem and storage:
Terminal
# Sync local folder to bucket
edge storage sync ./dist my-bucket/website/
# Sync bucket to local folder
edge storage sync my-bucket/backups/ ./local-backups/
# Sync with delete (remove files not in source)
edge storage sync --delete ./dist my-bucket/website/
# Dry run (show what would change)
edge storage sync --dry-run ./dist my-bucket/website/Presigned URLs#
Generate temporary URLs for private objects:
Text
# Generate presigned URL (default 1 hour)
$ edge storage presign my-bucket/private/document.pdf
https://storage.edge.network/my-bucket/private/document.pdf?X-Amz-...Terminal
# Custom expiry
edge storage presign my-bucket/file.zip --expires 24h
# Expiry options: 5m, 1h, 24h, 7d (max 7 days)Usage and metrics#
Overall usage#
Text
$ edge storage usage
Total Size: 48.2 GB
Total Objects: 12,345
Buckets: 5Bucket metrics#
Text
$ edge storage metrics my-bucket
Bucket: my-bucket
Region: london
Storage Used: 2.3 GB
Objects: 1,234
Created: 2025-01-15
$ edge storage metrics
Overall Storage Metrics
Total Storage: 48.2 GB
Total Objects: 12,345
Buckets: 5Common flags#
| Flag | Description |
|---|---|
-R, --recursive |
Operate recursively on folders (uppercase R) |
-f, --force |
Force delete bucket with contents / skip confirmation |
--delete |
Delete files not in source (sync only) |
--dry-run |
Show what would change without making changes (sync only) |
--expires |
Expiry time for presigned URLs (e.g. 1h, 24h, 7d) |
-r, --region |
Global flag for region selection |
Tips#
- Quiet mode for scripting: use the
-qflag to suppress progress output in scripts. - Very large files (1 GB+): for uploading very large files, consider using S3-compatible tools like
aws s3 cporrclone, which support multipart uploads with automatic retry and resumption.
Next steps
Something unclear or out of date? Tell us