sandbox.commands.run.
These commands run as root (the template’s default user, unless a
user build step changed it), so none of them use sudo.Amazon S3
Installs3fs in a template.
s3fs expects (ACCESS_KEY_ID:SECRET_ACCESS_KEY), then mount the bucket.
-o allow_other lets every process in the sandbox read the mount. Set endpoint and url to your bucket’s region: the example shows us-east-1, but s3fs needs them set explicitly for any other region (e.g. us-east-2). For the full option list, see the s3fs flags.
Google Cloud Storage
Google Cloud Storage usesgcsfuse. You’ll need a bucket and a service account with the Storage Object User role on it, plus a service account key.
Install gcsfuse from Google’s apt repository in a template.
--key-file.
gcsfuse flags.
Cloudflare R2
R2 is S3-compatible, so it reuses the sames3fs template. The only difference is the mount command, which points s3fs at your R2 endpoint.