Added Meteor-Files WRITEABLE_PATH for Sandstorm, Snap and Source.

Thanks to xet7 !

Related export WRITABLE_PATH=$SNAP_COMMON/wekan-uploads/
This commit is contained in:
Lauri Ojansivu 2022-03-02 17:32:34 +02:00
parent b378bb55ac
commit cc0658a225
4 changed files with 11 additions and 4 deletions

View file

@ -1127,7 +1127,8 @@ Migrations.add('add-card-details-show-lists', () => {
});
Migrations.add('migrate-attachments-collectionFS-to-ostrioFiles', () => {
const storagePath = Attachments.storagePath();
//const storagePath = Attachments.storagePath();
const storagePath = process.env.WRITABLE_PATH;
if (!fs.existsSync(storagePath)) {
console.log("create storagePath because it doesn't exist: " + storagePath);
fs.mkdirSync(storagePath, { recursive: true });