Skip to main content
skill CX Codex

tigris-s3-migration — Claude Code skill: move S3 data to Tigris

A skill that walks an object-storage migration from AWS S3, GCS or Azure Blob to Tigris. Useful when a bucket has to switch over without taking production down.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add tigrisdata/skills --skill tigris-s3-migration -a claude-code
Open on GitHub

What tigris-s3-migration does

The skill lays out three migration strategies: shadow bucket, bulk copy and incremental sync. The main one is the shadow bucket. Tigris serves an object from your existing S3 bucket on a cache miss, hands it back, and backfills its own copy. Nothing has to move up front.

Setup runs through the Tigris CLI. You create a bucket with tigris buckets create, then point it at the source with tigris buckets set-migration, passing the source bucket, endpoint, region and AWS keys. Adding --write-through also syncs new writes back to the source, which keeps a rollback path open. After that tigris buckets migrate drains every object that has not moved yet, and tigris buckets set-migration --disable makes Tigris the sole source.

Make sure the CLI is there first: tigris help || npm install -g @tigrisdata/cli. For GCS and Azure the skill ships bulk-copy commands built on gsutil and az storage blob download-batch. Files under ./resources/ show the endpoint swap for the AWS SDK in Node.js, Go, Python, Ruby and PHP. The usual breakage is a region hardcoded to us-east-1 — Tigris wants auto.

What it helps with

  • move a production bucket off AWS S3 onto Tigris with no downtime
  • set up a shadow bucket that backfills objects on demand
  • drain the remaining objects with tigris buckets migrate
  • copy data out of Google Cloud Storage or Azure Blob in bulk
  • swap the endpoint in the AWS SDK and environment variables

Example prompts for the agent

  • migrate the my-app-uploads bucket from S3 to Tigris using a shadow bucket
  • set up tigris buckets set-migration with --write-through so we can roll back
  • run tigris buckets migrate my-app-uploads/images/ and report progress

How to install tigris-s3-migration

1Skills CLI (Vercel)

npx skills add tigrisdata/skills --skill tigris-s3-migration -a claude-code

2Manually: put the files in place

~/.claude/skills/tigris-s3-migration/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/tigris-s3-migration/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about tigris-s3-migration

How do I install tigris-s3-migration in Claude?

Run npx skills add tigrisdata/skills --skill tigris-s3-migration -a claude-code. The skill lands at ~/.claude/skills/tigris-s3-migration/SKILL.md.

What does tigris-s3-migration do?

It handles an object-storage move to Tigris: shadow bucket setup, draining leftover objects, and the endpoint swap in your SDK and environment variables.

What do I need before running it?

The Tigris CLI. If tigris help fails, the skill installs it with npm install -g @tigrisdata/cli. A shadow bucket also needs access keys for the source bucket.

Source text

SKILL.md · MIT
---
name: tigris-s3-migration
description: Use when migrating from AWS S3, Google Cloud Storage, or Azure Blob to Tigris — shadow buckets via `tigris buckets set-migration`, active drain via `tigris buckets migrate`, bulk copy, SDK endpoint swap, zero-downtime migration
---

# Migrate to Tigris from S3/GCS/Azure

Migrate your object storage to Tigris with zero downtime. Tigris is S3-compatible, so most apps need only an endpoint and credential swap. Shadow buckets enable transparent migration without moving data upfront.

## Prerequisites

**Before doing anything else**, install the Tigris CLI if it's not already available:

```bash
tigris help || npm install -g @tigrisdata/cli
```

If you need to install it, tell the user: "I'm installing the Tigris CLI (`@tigrisdata/cli`) so we can work with Tigris object storage."

## Migration Strategies

| Strategy             | Downtime | Best For                                                                |
| -------------------- | -------- | ----------------------------------------------------------------------- |
| **Shadow bucket**    | Zero     | Production apps — Tigris reads from S3 on miss, backfills automatically |
| **Bulk copy**        | Brief    | Small datasets, clean cutover                                           |
| **Incremental sync** | Zero     | Large datasets, gradual migration                                       |

---

## Shadow Bucket (Recommended)

Tigris reads from your existing S3 bucket on cache miss and gradually backfills data. No upfront data movement needed.

```bash
# Create a Tigris bucket
tigris buckets create my-app-uploads
# Point the Tigris bucket at the source S3 bucket
tigris buckets set-migration my-app-uploads \
  --bucket my-existing-s3-bucket \
  --endpoint https://s3.us-east-1.amazonaws.com \
  --region us-east-1 \
  --access-key AKIA_YOUR_AWS_KEY \
  --secret-key YOUR_AWS_SECRET
```

Add `--write-through` to also sync new writes back to the source bucket — useful when you want a safe rollback path during the migration window.

**How it works:**

1. Requests go to Tigris
2. If the object exists in Tigris, it's served directly
3. If not, Tigris fetches it from S3, serves it, and caches it

**Migrate everything up front (optional):**

Lazy migration only copies objects when they're requested. To actively migrate every remaining object server-side, run:

```bash
# Migrate every unmigrated object in the bucket
tigris buckets migrate my-app-uploads

# Or scope to a key prefix
tigris buckets migrate my-app-uploads/images/
```

The command runs in the foreground and reports progress as it goes, so you can fully drain the source before cutting over.

**After migration completes:**

```bash
# Disable migration (makes Tigris the sole source)
tigris buckets set-migration my-app-uploads --disable
```

---

## Bulk Copy

For smaller datasets or when you want a clean cutover:

### From Google Cloud Storage

```bash
gsutil -m cp -r gs://my-gcs-bucket /tmp/migration/
tigris cp /tmp/migration/ t3://my-app-uploads/ -r
```

### From Azure Blob Storage

```bash
az storage blob download-batch -d /tmp/migration/ -s my-container
tigris cp /tmp/migration/ t3://my-app-uploads/ -r
```

---

## SDK Code Changes

Read the resource file for your language to see before/after migration examples:

- **Node.js / TypeScript** — Read `./resources/sdk-nodejs.md` for AWS SDK → Tigris SDK migration
- **Go** — Read `./resources/sdk-go.md` for AWS SDK → Tigris SDK migration
- **Python** — Read `./resources/sdk-python.md` for boto3 → tigris-boto3-ext migration, or use the **tigris-python-sdk** skill for the post-migration developer experience (Django, snapshots, forks, Bundle API)
- **Ruby** — Read `./resources/sdk-ruby.md` for aws-sdk-s3 endpoint swap
- **PHP** — Read `./resources/sdk-php.md` for aws-sdk-php endpoint swap

---

## Environment Variable Changes

```bash
# Before (AWS)
AWS_ACCESS_KEY_ID=AKIA...
AWS_SECRET_ACCESS_KEY=...
AWS_REGION=us-east-1
S3_BUCKET=my-bucket

# After (Tigris)
AWS_ACCESS_KEY_ID=tid_xxx
AWS_SECRET_ACCESS_KEY=tsec_yyy
AWS_ENDPOINT_URL_S3=https://t3.storage.dev
AWS_REGION=auto
S3_BUCKET=my-bucket  # bucket name can stay the same
```

For frameworks with specific Tigris env vars:

```bash
TIGRIS_STORAGE_ACCESS_KEY_ID=tid_xxx
TIGRIS_STORAGE_SECRET_ACCESS_KEY=tsec_yyy
TIGRIS_STORAGE_ENDPOINT=https://t3.storage.dev
TIGRIS_STORAGE_BUCKET=my-bucket
```

---

## Verification Checklist

- [ ] Object count matches between source and Tigris
- [ ] Spot-check files: download a few and verify content/checksums
- [ ] Test presigned URL generation (endpoint must point to Tigris)
- [ ] Test CORS if using browser uploads (reconfigure on Tigris bucket)
- [ ] Test all upload/download code paths in staging
- [ ] Update CDN origin if using CloudFront/similar (point to Tigris)
- [ ] Update DNS if using custom domains

---

## Rollback Strategy

1. Keep source bucket read-only during migration (don't delete data)
2. Run both systems in parallel during verification
3. Only delete source data after confirming Tigris works fully
4. If using shadow bucket, removing the shadow source is the point of no return

---

## Common Mistakes

| Mistake                                 | Fix                                                                                |
| --------------------------------------- | ---------------------------------------------------------------------------------- |
| Forgot to update presigned URL endpoint | Presigned URLs must use Tigris endpoint, not S3                                    |
| CORS not configured on Tigris           | Re-create CORS rules: `tigris buckets cors set`                                    |
| Region hardcoded to `us-east-1`         | Use `auto` for Tigris                                                              |
| `path_style` not set                    | Add `force_path_style: true` (Ruby/Rails) or `use_path_style_endpoint: true` (PHP) |
| Custom domain DNS still points to S3    | Update CNAME to point to Tigris                                                    |

---

## Related Skills

- **file-storage** — CLI setup and SDK reference
- **tigris-security-access-control** — CORS and access key setup

## Official Documentation

- S3 Compatibility: https://www.tigrisdata.com/docs/sdks/s3/
- Shadow Buckets & migration: https://www.tigrisdata.com/docs/migration/
- CLI: `tigris buckets set-migration` — https://www.tigrisdata.com/docs/cli/buckets/set-migration
- CLI: `tigris buckets migrate` — https://www.tigrisdata.com/docs/cli/buckets/migrate

© tigrisdata · MIT · tigrisdata/skills

Similar skills

Everything for DevOps and infrastructure →

From the same set5

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor