fix(docker): add missing deps to db container for running script#2746
Merged
waleedlatif1 merged 1 commit intostagingfrom Jan 9, 2026
Merged
fix(docker): add missing deps to db container for running script#2746waleedlatif1 merged 1 commit intostagingfrom
waleedlatif1 merged 1 commit intostagingfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Greptile Overview
Greptile Summary
Fixes missing dependencies in the database Docker container that prevented SSO registration script from running successfully.
- Added
uuidpackage dependency topackages/db/package.json(used byregister-sso-provider.tsandmigrate-deployment-versions.tsscripts) - Added root
package.jsoncopy to Dockerfile for workspace dependency resolution (required by Bun to resolve workspace packages like@sim/tsconfig) - Fixed documentation path in script comment to reflect correct location
Confidence Score: 5/5
- This PR is safe to merge - it adds necessary missing dependencies without introducing any risks
- The changes are straightforward dependency additions that fix a real bug. The uuid package is required by two scripts (register-sso-provider.ts and migrate-deployment-versions.ts), and the root package.json is needed for Bun's workspace resolution. All changes are properly reflected in the lockfile, and the documentation fix ensures clarity for users.
- No files require special attention
Important Files Changed
File Analysis
| Filename | Score | Overview |
|---|---|---|
| docker/db.Dockerfile | 5/5 | Added copy of root package.json for workspace resolution - necessary for Bun to resolve workspace dependencies when running scripts in the container |
| packages/db/package.json | 5/5 | Added uuid dependency (^11.1.0) to support UUID generation in database scripts |
| packages/db/scripts/register-sso-provider.ts | 5/5 | Updated usage comment to correct script path (scripts/register-sso-provider.ts instead of register-sso-provider.ts) |
| bun.lock | 5/5 | Lockfile updated to include uuid dependency for packages/db |
Sequence Diagram
sequenceDiagram
participant DC as Docker Compose
participant DB as db.Dockerfile
participant Bun as Bun Runtime
participant Script as register-sso-provider.ts
participant PG as PostgreSQL
DC->>DB: Build migrations container
DB->>DB: Copy root package.json (NEW)
DB->>DB: Copy node_modules with uuid
DB->>DB: Copy packages/tsconfig
DB->>DB: Copy packages/db
DC->>Bun: Run script in container
Bun->>Bun: Resolve workspace deps via package.json
Bun->>Script: Execute register-sso-provider.ts
Script->>Script: Import uuid package (NEW)
Script->>Script: Generate UUID with uuidv4()
Script->>PG: Insert SSO provider with UUID
PG-->>Script: Success
Script-->>Bun: Complete
Bun-->>DC: Exit 0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Type of Change
Testing
Tested manually
Checklist