neon-object-storage
Skill này làm gì
Dịch vụ này cho phép bạn lưu tệp (như ảnh hoặc tài liệu) theo cách luôn đồng bộ với cơ sở dữ liệu của dự án Neon. Mỗi 'branch' của dự án sẽ có không gian lưu trữ riêng, tách biệt.
Khi nào nên dùng
- ✓Khi bạn đã dùng Neon cho cơ sở dữ liệu và muốn một nơi duy nhất cho cả dữ liệu lẫn tệp.
- ✓Khi điều quan trọng là tệp và dữ liệu luôn được cập nhật cùng nhau qua các phiên bản khác nhau của dự án.
- ✓Khi bạn muốn thử nghiệm thay đổi với tệp mà không gây rủi ro cho dữ liệu quan trọng.
Liên kết skill
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/neon-object-storage/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Làm sao để thiết lập lưu trữ tệp để nó theo dõi các branch của cơ sở dữ liệu Neon?”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Bạn định nghĩa các 'bucket' lưu trữ mong muốn trong file cấu hình của dự án Neon (`neon.ts`). Sau đó, một lệnh đơn giản sẽ tạo chúng, và Neon đảm bảo mọi thứ được đồng bộ với các branch cơ sở dữ liệu.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Neon Object Storage
This is a preview feature and only available in us-east-2. Neon Object Storage is S3-compatible object storage that branches with your projects: every branch gets its own isolated storage state, so files and database rows stay in sync across dev, preview, staging, and production.
Use this skill to help the user store and serve files that branch alongside their database. Deliver a working bucket and upload/download flow, a branch-aware S3 client wired to the injected env vars, or a precise answer from the official Neon docs.
When to Use
Reach for Neon Object Storage when the user needs to store files (images, uploads, generated assets, documents, backups) and any of the following are true:
- They already use Neon Postgres and don't want a second provider. One backend, one bill, one CLI, one set of branches — instead of standing up and wiring a separate AWS S3 / R2 / Supabase Storage account. The same Neon credential that backs the database backs storage.
- Files must stay in sync with the database across environments. Storage branches together with your Postgres data. Fork a branch and the child instantly inherits the parent's buckets and objects at that point in time — copy-on-write, so no data is duplicated. This is what makes agent, dev, preview, and test environments seamless: a preview branch gets a consistent snapshot of both the rows and the files they reference, and writes on the child never touch the parent.
- They want safe, throwaway environments. Upload, overwrite, and delete files in a preview/CI branch without any risk to production data, then drop the branch.
- They want standard S3 tooling. It's built on S3 semantics and speaks the S3 API, so the AWS SDKs,
boto3, the AWS CLI, and presigned URLs all work — reliable and familiar, with no proprietary client.
If the user has no Neon project, isn't on Postgres, and just needs a standalone CDN-backed asset store, a dedicated object store may fit better — but the moment branch-consistent files + rows matter, this is the reason to use it.
What It Does
- S3-compatible — Works with existing S3 SDKs,
boto3, the AWS CLI, and presigned URLs. Path-style addressing and SigV4 only. - Branches with your database — Every Neon branch gets its own isolated, copy-on-write storage state. Forking copies no data.
- Two access modes —
privatebuckets require a credential for every operation;public_readbuckets allow anonymous reads with authenticated writes. - One credential system — The same Neon credential system used by Functions and the AI Gateway.
Setup
Object storage is part of the neon.ts infrastructure-as-code config (see the neon skill for the branch-first workflow, link/checkout, and neon.ts basics). Declare buckets under preview.buckets, keyed by bucket name:
// neon.ts
import { defineConfig } from "@neon/config/v1";
export default defineConfig({
preview: {
buckets: {
images: {}, // private by default
"public-assets": { access: "public_read" },
},
},
});
Provision the declared buckets on the linked branch:
neon deploy # alias for `neon config apply`
Neon Infrastructure as Code (neon.ts)
The preview.buckets block above is part of neon.ts, Neon's infrastructure-as-code file — one TypeScript file declares your buckets alongside every other service the branch should have (see the neon skill for the full reference). Reconcile the declaration against a branch the Terraform way:
neon config status # print the branch's live config (which buckets exist)
neon config plan # dry-run diff of what apply would change
neon config apply # create the declared buckets (neon deploy is an alias)
Buckets are branch-scoped: when a neon.ts is present, neon checkout applies the policy as it creates a branch, so a fresh preview/CI branch comes up with its buckets already provisioned (and copy-on-write objects inherited from the parent). Checking out an existing branch doesn't reconcile it — run neon deploy to apply changes. Provisioning (config apply / deploy), link, and checkout also pull the branch's S3 credentials into your local .env.local, so the same env pull step shown below happens for you on those commands.
…
Câu hỏi thường gặp
“S3-compatible” nghĩa là gì?
Nghĩa là dịch vụ dùng chuẩn giao tiếp (API) rất phổ biến cho lưu trữ tệp, giống như chuẩn của Amazon S3. Nhờ vậy, bạn có thể dùng các công cụ và thư viện quen thuộc.
“Branch” trong ngữ cảnh này là gì?
Đó là các bản sao của dự án để thử nghiệm tính năng mới hoặc thay đổi mà không ảnh hưởng đến phiên bản chính. Dịch vụ này đảm bảo mỗi branch có tệp riêng, đồng bộ với dữ liệu của branch đó.
Tôi có thể đặt tệp ở chế độ công khai hoặc riêng tư không?
Có. Bạn có thể cấu hình các 'bucket' ở chế độ riêng tư (cần đăng nhập để truy cập) hoặc công khai chỉ đọc (ai cũng xem được, nhưng chỉ bạn mới thêm hoặc sửa được).
Chi tiết
Mô tả gốc của tác giả
S3-compatible object storage that branches with your Neon project, so files and the database stay in sync across every branch.
Độ phổ biến
- Sao GitHub
- 48k
- Vị trí xếp hạng
- #5283
- Giấy phép
- MIT
- Cập nhật
- 15/10/2026
Bình luận
- …
Thêm skill từ kho mã này
00-andruia-consultant
48kGiúp agent của bạn bắt đầu hoặc cải thiện các dự án AI. Phân tích mã, gợi ý công cụ và lập kế hoạch hành động bằng tiếng Tây Ban Nha.
007
48kCho phép agent của bạn thực hiện kiểm toán bảo mật và mô hình hóa mối đe dọa. Hữu ích để bảo vệ dự án khỏi các cuộc tấn công và lỗ hổng.
10-andruia-skill-smith
48kGiúp agent của bạn tạo hoặc cải thiện các công cụ AI. Xác định cách công cụ hoạt động, viết tài liệu và kiểm tra cấu trúc.
20-andruia-niche-intelligence
48kGiúp agent của bạn tạo bản tóm tắt về một ngành cụ thể. Hữu ích để hiểu bối cảnh, quy tắc, cách người dùng tương tác và rủi ro của dự án.
Skill tương tự
discrawl
394kCho phép agent của bạn tìm kiếm và tóm tắt kho lưu trữ tin nhắn Discord trên máy, kiểm tra độ mới của dữ liệu và đọc tin nhắn trực tiếp.
clickhouse-io
280kGiúp agent của bạn tối ưu truy vấn và schema trong ClickHouse theo thực hành tốt nhất cho phân tích dữ liệu hiệu năng cao khi truy vấn chậm.
scientific-db-pubmed-database
280kGiúp agent của bạn tìm bài báo khoa học trong lĩnh vực y sinh. Hữu ích cho nghiên cứu cần thông tin y khoa cụ thể.