mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-17 10:59:39 +02:00
♻️ refactor(storage): unify bucket names and add calendar/contacts
- Rename buckets to consistent {project}-storage pattern
- Add calendar-storage and contacts-storage buckets
- Add createCalendarStorage() and createContactsStorage() factory functions
- Update docker-compose and documentation
This commit is contained in:
parent
ef8fd6a101
commit
29aaaec4fa
7 changed files with 70 additions and 26 deletions
|
|
@ -105,3 +105,17 @@ export function createNutriPhiStorage(publicUrl?: string): StorageClient {
|
|||
export function createPresiStorage(): StorageClient {
|
||||
return createStorageClient({ name: BUCKETS.PRESI });
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a storage client for the Calendar project
|
||||
*/
|
||||
export function createCalendarStorage(): StorageClient {
|
||||
return createStorageClient({ name: BUCKETS.CALENDAR });
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a storage client for the Contacts project
|
||||
*/
|
||||
export function createContactsStorage(): StorageClient {
|
||||
return createStorageClient({ name: BUCKETS.CONTACTS });
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ export {
|
|||
createManaDeckStorage,
|
||||
createNutriPhiStorage,
|
||||
createPresiStorage,
|
||||
createCalendarStorage,
|
||||
createContactsStorage,
|
||||
} from './factory.js';
|
||||
|
||||
// Utilities
|
||||
|
|
|
|||
|
|
@ -76,11 +76,13 @@ export interface FileInfo {
|
|||
* Predefined bucket names for each project
|
||||
*/
|
||||
export const BUCKETS = {
|
||||
PICTURE: 'picture-images',
|
||||
CHAT: 'chat-files',
|
||||
MANADECK: 'manadeck-assets',
|
||||
NUTRIPHI: 'nutriphi-meals',
|
||||
PRESI: 'presi-slides',
|
||||
PICTURE: 'picture-storage',
|
||||
CHAT: 'chat-storage',
|
||||
MANADECK: 'manadeck-storage',
|
||||
NUTRIPHI: 'nutriphi-storage',
|
||||
PRESI: 'presi-storage',
|
||||
CALENDAR: 'calendar-storage',
|
||||
CONTACTS: 'contacts-storage',
|
||||
} as const;
|
||||
|
||||
export type BucketName = (typeof BUCKETS)[keyof typeof BUCKETS];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue