feat(bucket): auto-create buckets and move files from temp to main buckets on property save
deploy-chabokan / deploy (push) Canceled after 0s

This commit is contained in:
2026-08-19 04:58:14 +03:30
parent dd611df7e5
commit 31ebafb53c
4 changed files with 96 additions and 10 deletions
+6
View File
@@ -23,6 +23,12 @@ module.exports = (app) => {
const { syncPermissions } = require('../components/permission/permissionService')
await syncPermissions()
// Ensure default MinIO buckets exist (temp, properties, documents)
const { ensureBucketsExist } = require('../utils/upload/bucket')
await ensureBucketsExist(['temp', 'properties', 'documents']).catch((err) => {
console.error('Failed to ensure default MinIO buckets:', err)
})
app.listen(port, function () {
console.log('Server Started On Port ' + port)
})