fix: declare @tailwindcss/postcss in admin/space/web Docker builds - #9189
Conversation
The web/admin/space Docker image builds fail at the Vite/PostCSS step with "Cannot find module '@tailwindcss/postcss'". These apps load the shared @plane/tailwind-config/postcss.config.js, which references the @tailwindcss/postcss plugin by name, but the plugin was only declared as a dependency of packages/tailwind-config. The Docker build installs via turbo prune + 'pnpm fetch' + 'pnpm install --offline', which lays out node_modules so PostCSS resolves the plugin relative to the app directory (apps/<app>), where it is not reachable. A plain 'pnpm install' resolves it from tailwind-config's context instead, which is why local builds passed and masked the issue. Declare @tailwindcss/postcss as a direct devDependency of the three apps that run Vite/PostCSS so it is symlinked into each app's node_modules and resolves under the isolated linker regardless of install flow. Verified by reproducing the exact Docker flow (prune -> fetch -> --frozen-lockfile offline install -> build) for admin, space and web: all install in sync and build successfully with full Tailwind CSS output.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThe PR adds the ChangesTailwind CSS PostCSS dependencies
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
Fixes Docker CI failures for the web, admin, and space app images where Vite/PostCSS cannot resolve @tailwindcss/postcss during the pruned/offline pnpm install flow by ensuring the plugin is installed in each app’s own dependency context.
Changes:
- Add
@tailwindcss/postcssas a directdevDependencyofapps/admin,apps/space, andapps/web. - Update
pnpm-lock.yamlwith the new importer edges (no version bumps).
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
apps/admin/package.json |
Adds @tailwindcss/postcss to devDependencies so PostCSS plugin resolution works in pruned Docker installs. |
apps/space/package.json |
Adds @tailwindcss/postcss to devDependencies to make plugin resolution reliable in CI Docker builds. |
apps/web/package.json |
Adds @tailwindcss/postcss to devDependencies to prevent Vite/PostCSS config load failures in Docker builds. |
pnpm-lock.yaml |
Records the new dependency edges for the three app importers. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
makeplane#9189) The web/admin/space Docker image builds fail at the Vite/PostCSS step with "Cannot find module '@tailwindcss/postcss'". These apps load the shared @plane/tailwind-config/postcss.config.js, which references the @tailwindcss/postcss plugin by name, but the plugin was only declared as a dependency of packages/tailwind-config. The Docker build installs via turbo prune + 'pnpm fetch' + 'pnpm install --offline', which lays out node_modules so PostCSS resolves the plugin relative to the app directory (apps/<app>), where it is not reachable. A plain 'pnpm install' resolves it from tailwind-config's context instead, which is why local builds passed and masked the issue. Declare @tailwindcss/postcss as a direct devDependency of the three apps that run Vite/PostCSS so it is symlinked into each app's node_modules and resolves under the isolated linker regardless of install flow. Verified by reproducing the exact Docker flow (prune -> fetch -> --frozen-lockfile offline install -> build) for admin, space and web: all install in sync and build successfully with full Tailwind CSS output.
makeplane#9189) The web/admin/space Docker image builds fail at the Vite/PostCSS step with "Cannot find module '@tailwindcss/postcss'". These apps load the shared @plane/tailwind-config/postcss.config.js, which references the @tailwindcss/postcss plugin by name, but the plugin was only declared as a dependency of packages/tailwind-config. The Docker build installs via turbo prune + 'pnpm fetch' + 'pnpm install --offline', which lays out node_modules so PostCSS resolves the plugin relative to the app directory (apps/<app>), where it is not reachable. A plain 'pnpm install' resolves it from tailwind-config's context instead, which is why local builds passed and masked the issue. Declare @tailwindcss/postcss as a direct devDependency of the three apps that run Vite/PostCSS so it is symlinked into each app's node_modules and resolves under the isolated linker regardless of install flow. Verified by reproducing the exact Docker flow (prune -> fetch -> --frozen-lockfile offline install -> build) for admin, space and web: all install in sync and build successfully with full Tailwind CSS output.
Description
The Web, Admin, and Space Docker image builds in the "Branch Build CE" workflow fail at the Vite/PostCSS step with:
Root cause:
apps/{admin,space,web}/postcss.config.jsre-export the shared@plane/tailwind-config/postcss.config.js, which references the@tailwindcss/postcssplugin by name. The plugin was declared only as a dependency ofpackages/tailwind-config, never of the apps themselves.The Docker build installs deps via
turbo prune --docker→pnpm fetch→pnpm install --offline. That flow lays outnode_modulesso PostCSS resolves the plugin relative to the app directory (apps/<app>), where it is not reachable. A plainpnpm installhappens to resolve it fromtailwind-config's context instead — which is why local builds passed and masked the bug. (Note: this is pre-existing and not caused by the recent pnpm-catalog migration — earlier runs failed identically. Hoisting via.npmrcis not an option because pnpm v11 ignores the repo's.npmrcpnpm-settings.)Fix: Declare
@tailwindcss/postcss: catalog:as a direct devDependency of the three apps that run Vite/PostCSS, alongside the already-direct@tailwindcss/typography. Under the isolated linker, direct deps are always symlinked into the package's ownnode_modules, so the plugin resolves from each app's context regardless of the install flow.pnpm-lock.yamlis updated with the three importer edges only (no version changes).Type of Change
Screenshots and Media (if applicable)
Test Scenarios
Verified by reproducing the exact CI Docker install flow locally (
turbo prune --scope=<app> --docker→pnpm fetch→pnpm install --offline --frozen-lockfile --prod=false→turbo run build --filter=<app>) for all three apps:--frozen-lockfileinstall passing confirms the lockfile is in sync with thepackage.jsonchanges (no CI drift).References
🤖 Generated with Claude Code
Summary by CodeRabbit