@dooer/dooer-test-env 1.2.1 → 1.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -177,6 +177,18 @@ function profilesFor(name) {
177
177
  return BOOKING_PROFILE_SERVICES.includes(name) ? ['full', 'booking', 'hq'] : ['full']
178
178
  }
179
179
 
180
+ // S3 buckets the services expect (MinIO starts empty; on staging these are OBC-provisioned). Missing ones
181
+ // cause `NoSuchBucket` on document upload / event-stream large-payload offload. The event-stream bucket name
182
+ // is stream-name-derived by the client (`${streamName}-event-stream-large-payloads`). (Jimmy 2026-09-03.)
183
+ const S3_BUCKETS = [
184
+ 'file-storage-bucket', // service-file-storage (document blobs)
185
+ 'institution-browser-bucket', // service-institution-browser
186
+ `${GLOBAL_OVERRIDES.DOOER_STREAM_NAME}-event-stream-large-payloads`, // @dooer/event-stream large payloads
187
+ 's-e032-service-xrays', // service-xrays (DOOER_BUCKET_NAME, a plain manifest value)
188
+ 'd-e023-b01-s09-dooer', // DOOER_LEGACY_STORAGE_BUCKET (read fallback)
189
+ 'l-e025-b01-s09-dooer', // DOOER_LEGACY_STORAGE_BUCKET_FALLBACK
190
+ ]
191
+
180
192
  // The infra containers every profile needs (no `profiles:` → always started).
181
193
  function infraServices() {
182
194
  return {
@@ -255,6 +267,19 @@ function infraServices() {
255
267
  volumes: ['minio_data:/data'],
256
268
  restart: 'unless-stopped',
257
269
  },
270
+ // One-shot: wait for MinIO, then create the buckets the services expect (idempotent). Runs on every `up`.
271
+ 'minio-init': {
272
+ image: 'minio/mc:latest',
273
+ platform: 'linux/amd64',
274
+ depends_on: ['minio'],
275
+ entrypoint: [
276
+ '/bin/sh',
277
+ '-c',
278
+ `until mc alias set local http://minio:9000 ${DEV.minioUser} ${DEV.minioPassword} >/dev/null 2>&1; do sleep 1; done; ` +
279
+ `${S3_BUCKETS.map((b) => `mc mb --ignore-existing local/${b}`).join('; ')}; echo minio-init done`,
280
+ ],
281
+ restart: 'no',
282
+ },
258
283
  // Mutable name→endpoint registry that speaks the Consul health API. Build context is an ABSOLUTE
259
284
  // path to the repo's discovery-router, so it resolves no matter where the compose file is written
260
285
  // (it lives in ~/.dooer-test-env, not the repo).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dooer/dooer-test-env",
3
- "version": "1.2.1",
3
+ "version": "1.2.2",
4
4
  "description": "Run the whole Dooer backend locally (staging DB minus customers), copy/purge customers between environments, and shred — one CLI.",
5
5
  "license": "UNLICENSED",
6
6
  "repository": "Dooer/cli-dooer-test-env",