मुख्य सामग्री पर जाएँ
Skillpedia
API और सर्वर (backend)25k · #10084

nocobase-drive

यह क्या करती है

यह स्किल NocoBase 3 ऐप में फ़ाइल स्टोरेज कॉन्फ़िगर करती है, जिसमें लोकल फ़ोल्डर, S3-compatible सेवाएँ और Aliyun OSS शामिल हैं। यह उन डेवलपर्स के लिए है जो अपलोड और स्टोरेज सेटिंग संभालते हैं।

कब इस्तेमाल करें

  • ✓जब आपको बदलना हो कि NocoBase ऐप अपलोड की गई फ़ाइलें कहाँ सेव करे।
  • ✓जब आप ऐप को S3 या Aliyun OSS स्टोरेज से जोड़ना चाहें।
  • ✓जब फ़ाइल ऑपरेशन या स्टोरेज URL कैसे बने हैं, यह ठीक करना हो।

Skill का लिंक

https://github.com/nocobase/nocobase/blob/v3-develop/packages/libs/drive/skills/nocobase-drive/SKILL.md

इसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।

कैसे इस्तेमाल करें

सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।

पेस्ट करने के लिए तैयार मैसेज

इस skill से मेरी मदद करो: https://github.com/nocobase/nocobase/blob/v3-develop/packages/libs/drive/skills/nocobase-drive/SKILL.md इस लिंक की SKILL.md फ़ाइल पढ़ो और मेरे काम में उसके निर्देशों का पालन करो।
क्या आप चाहते हैं कि आपका AI ऐसी skills खुद ढूँढे?मुफ़्त Skillpedia MCP इंस्टॉल करें: बस एक लाइन, और हर काम से पहले यह 15,000+ skills में खोजता है।1 मिनट में इंस्टॉल करें →

AI से क्या माँगें: उदाहरण

“क्या आप मेरे NocoBase ऐप को अपलोड की गई फ़ाइलें लोकल डिस्क के बजाय S3 बकेट में सेव करने के लिए सेट कर सकते हैं?”

हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।

यह कैसे काम करती है

AI स्टोरेज कॉन्फ़िगरेशन बदलता है और स्टोरेज प्रकार के लिए सही ड्राइवर चुनता है। फिर वह फ़ाइल ऑपरेशन और ऐप द्वारा बनाए गए URL जाँचता है।

तकनीकी सामग्री (मूल SKILL.md)

लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।

File storage with NocoBase Drive

Use @nocobase/drive for storage operations. It wraps Flydrive with application configuration and a native Aliyun OSS driver. Choose the relevant reference before changing a disk:

Storage Driver Read
A local or mounted filesystem fs Filesystem configuration, paths, and URLs
Amazon S3 or an S3-compatible service s3 S3 configuration, credentials, and ACLs
Native Aliyun OSS with access keys or an ECS RAM role oss OSS configuration, credentials, and networking
An application-owned or third-party Flydrive driver Factory function Custom driver factories

Configuration and application integration

Configure default and disks in server/config/drive.ts; config.yml can override serializable object options. A disk name is the key in disks, while driver selects an implementation. For example, local: { driver: 'fs', ... } is selected by drive.use('local'). default must name an entry in disks. Objects and synchronous factories can coexist; no separate services configuration or driver registry is required.

Keep the application's existing DriveProvider and import driveManagerToken from @nocobase/app-server/drive. In server code that already has an application instance:

import { driveManagerToken } from '@nocobase/app-server/drive';

const drive = app.container.resolve(driveManagerToken);
const disk = drive.use();

await disk.put('reports/example.txt', 'Example report');
const contents = await disk.get('reports/example.txt');

Use drive.use(name) to select another disk. Pass storage keys relative to that disk, such as reports/example.txt; do not pass an absolute filesystem path, a URL, or a pre-encoded key. The manager creates disks on first use and caches successful creation. Resolve the shared manager instead of constructing one per request.

File Repository selects these same disks by name. Use the installed File plugin for file records, Repository upload/download operations, and their permissions. Direct Drive operations do not create File Repository records or perform its authorization checks. Changing the default disk does not move stored objects or rewrite existing records.

Boundaries and verification

visibility does not itself guarantee HTTP access or isolation. Filesystem serving and object storage policies determine actual access; generating a public URL does not grant permission to a private object. Read the selected driver's URL behavior before exposing a link.

Release artifact storage needs serializable configuration. Custom factories are rejected when selected by releases.artifact.disk. Named artifact references currently accept private fs and s3 objects; use the complete OSS object directly under releases.artifact or host.artifact for OSS, as the OSS guide describes.

For standalone use, call prepareDriveStorage(config) before createDriveManager(config) when filesystem directory preparation is needed. The application Provider already performs preparation. Tests can supply createDriveManager(config, { fakes: { location } }) and use Flydrive's fake()/restore(); fakes verify application behavior without proving remote credentials, ACLs, or network access.

Verify a configuration change with a write, read or streamed download, and deletion under a disposable key. Check public or signed links from the intended client's network when the feature uses them. Report whether verification used local storage, fakes, or the real remote service. For custom drivers, also verify lazy creation and repeated use through the shared manager.

अक्सर पूछे जाने वाले सवाल

क्या इसमें अपलोड की अनुमतियाँ शामिल हैं?

नहीं। फ़ाइल कलेक्शन और अपलोड की अनुमतियाँ File plugin के पास हैं।

क्या मैं सूची में न दिया गया स्टोरेज प्रकार इस्तेमाल कर सकता हूँ?

हाँ। स्किल दूसरी सेवाओं के लिए कस्टम ड्राइवर फ़ैक्टरी भी बताती है।

क्या यह स्टोरेज क्रेडेंशियल भी कवर करती है?

हाँ। यह बताती है कि हर स्टोरेज प्रकार के लिए क्रेडेंशियल कैसे सेट होते हैं।

जानकारी

लेखक का मूल विवरण

Configure and use file storage with @nocobase/drive in NocoBase 3 applications, including local filesystem, S3-compatible storage, native Aliyun OSS, and custom driver factories. Use when changing drive configuration, storage credentials, file operations, or storage URLs. File Repository collections and upload permissions belong to the File plugin.

repo: nocobase/nocobase

लोकप्रियता

GitHub स्टार
25k
रैंकिंग में स्थान
#10084
लाइसेंस
—
अपडेट की गई
2/11/2026

क्या यह skill काम की है?

0

लॉग इन करें वोट करने के लिए।

कमेंट

  • …

इस repository की और skills

nocobase-app-development

25k

यह आपके एजेंट को पूर्ण NocoBase 3 व्यावसायिक एप्लिकेशन के लिए पेज, routes, डेटा, अनुमतियाँ और टेस्ट बनाने में मदद करती है।

कोडिंगसामान्य कोडिंग

shadcn

25k

यह आपके एजेंट को वेब प्रोजेक्ट में shadcn/ui कंपोनेंट खोजने, जोड़ने, ठीक करने और स्टाइल करने में मदद करती है, उनके आधिकारिक दस्तावेज़ और registries का उपयोग करके।

कोडिंगवेबसाइट और UI (frontend)

nocobase-app-plugin-development

25k

यह आपके एजेंट को मौजूदा NocoBase 3 ऐप के भीतर plugins बनाने और उनकी देखभाल करने में मदद करती है, जिसमें server, client, database और registration के हिस्से शामिल हैं।

कोडिंगAPI और सर्वर (backend)

nocobase-app-upgrade

25k

यह आपके एजेंट को NocoBase ऐप को नए template रिलीज़ तक अपग्रेड करने में मदद करती है, template के बदलाव लाते हुए आपका अपना काम बनाए रखते हुए।

कोडिंगडिप्लॉय और क्लाउड (DevOps)

मिलती-जुलती skills