diff --git a/hosting/docker-compose.dev.yaml b/hosting/docker-compose.dev.yaml index 3b99ef796c..eaced64e06 100644 --- a/hosting/docker-compose.dev.yaml +++ b/hosting/docker-compose.dev.yaml @@ -14,7 +14,6 @@ services: environment: MINIO_ACCESS_KEY: ${MINIO_ACCESS_KEY} MINIO_SECRET_KEY: ${MINIO_SECRET_KEY} - MINIO_BROWSER: "off" command: server /data healthcheck: test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"] diff --git a/packages/server/src/api/controllers/static/index.js b/packages/server/src/api/controllers/static/index.js index 64cfb122f7..8eac910261 100644 --- a/packages/server/src/api/controllers/static/index.js +++ b/packages/server/src/api/controllers/static/index.js @@ -71,7 +71,7 @@ exports.uploadFile = async function (ctx) { return prepareUpload({ file, - s3Key: `assets/${ctx.appId}/attachments/${processedFileName}`, + s3Key: `/${ctx.appId}/attachments/${processedFileName}`, bucket: ObjectStoreBuckets.APPS, }) }) diff --git a/packages/server/src/api/routes/tests/row.spec.js b/packages/server/src/api/routes/tests/row.spec.js index ce7d76100b..60796e56f1 100644 --- a/packages/server/src/api/routes/tests/row.spec.js +++ b/packages/server/src/api/routes/tests/row.spec.js @@ -385,7 +385,7 @@ describe("/rows", () => { name: "test", description: "test", attachment: [{ - key: `${config.getAppId()}/attachment/test/thing.csv`, + key: `${config.getAppId()}/attachments/test/thing.csv`, }], tableId: table._id, }) @@ -393,7 +393,7 @@ describe("/rows", () => { await setup.switchToSelfHosted(async () => { const enriched = await outputProcessing(config.getAppId(), table, [row]) expect(enriched[0].attachment[0].url).toBe( - `/prod-budi-app-assets/${config.getAppId()}/attachment/test/thing.csv` + `/prod-budi-app-assets/${config.getAppId()}/attachments/test/thing.csv` ) }) })