PR_26177_CHARLIE_007-runtime-configuration-complete#216
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d1a7b2d076
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| projectsPrefix: "", | ||
| bucket: envValue(env, "GAMEFOUNDRY_STORAGE_BUCKET"), | ||
| endpoint: safeStorageEndpointValue(envValue(env, "GAMEFOUNDRY_STORAGE_ENDPOINT")), | ||
| projectsPrefix: normalizeStorageProjectsPrefix(envValue(env, "GAMEFOUNDRY_STORAGE_PROJECTS_PREFIX")), |
There was a problem hiding this comment.
Validate partial storage prefixes before exposing them as safe
When any required storage credential is missing, this early return skips the allowed-prefix validation but still publishes the normalized GAMEFOUNDRY_STORAGE_PROJECTS_PREFIX in safe. In a partial environment such as a configured endpoint/bucket with missing keys and GAMEFOUNDRY_STORAGE_PROJECTS_PREFIX=/qa/projects/, ownerStorageStatus() later treats any non-empty safe.projectsPrefix as PASS, so System Health/R2 readiness can show an unapproved storage lane as configured instead of warning about the invalid prefix. Validate the prefix before returning partial safe data or carry a validation error/status for it.
Useful? React with 👍 / 👎.
Summary
/local/projects/to the approved project storage prefix contractValidation
node --check scripts/start-local-api-server.mjsnode --check src/dev-runtime/server/local-api-router.mjsnode --check src/dev-runtime/storage/storage-config.mjsnode --check tests/dev-runtime/AdminHealthOperations.test.mjsnode --check tests/dev-runtime/LocalApiStartupLogging.test.mjsnode --check tests/dev-runtime/StorageConfig.test.mjsnode --test tests/dev-runtime/LocalApiStartupLogging.test.mjs tests/dev-runtime/StorageConfig.test.mjs tests/dev-runtime/PublicEnvironmentConfig.test.mjs tests/dev-runtime/PublicApiUrlClient.test.mjs tests/dev-runtime/AdminHealthOperations.test.mjs tests/api/admin-system-health/contract.test.mjsnpx playwright test tests/playwright/tools/AdminHealthOperationsPage.spec.mjs --workers=1git diff --checkArtifacts
tmp/PR_26177_CHARLIE_007-runtime-configuration-complete_delta.zipdocs_build/dev/reports/PR_26177_CHARLIE_007-runtime-configuration-complete.md