-
Notifications
You must be signed in to change notification settings - Fork 55
chore: restructure into a monorepo using pnpm #2140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Elessar1802
wants to merge
24
commits into
develop
Choose a base branch
from
chore/pnpm
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 4 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
0f98d80
feat(repo)!: restructure into a monorepo
Elessar1802 477ff64
chore: update Dockerfile(s) & allow build on arm
Elessar1802 a377eb1
chore: remove --frozen-lockfile option due to fe-lib dep
Elessar1802 f29ec8d
chore: update Dockerfile.web to override devtron-fe-lib if mounted
Elessar1802 fa41428
fix: build command in package.json & revert target url in vite.config…
Elessar1802 2357887
fix: enable HMR for packages in dashboard
Elessar1802 d66ede3
fix: use import statement for devtron-fe-lib
Elessar1802 dfb04b9
fix: review comments
Elessar1802 3c139b6
chore: add scripts for storybook in root package.json
Elessar1802 c8ecd25
fix(lint): lint --fix applied on all files
Elessar1802 3983993
fix: broken tsconfig.json
Elessar1802 ba3cb85
feat: add lint-staged & break lint into compile & lint
Elessar1802 dfd122d
chore: change author of fe-lib dummy repo
Elessar1802 41a30d9
chore: update README.md to reflect latest changes
Elessar1802 ffcf475
fix: link to release verion in README.md
Elessar1802 0562505
chore: mention correct license in package.json
Elessar1802 b4365b4
chore: remove author and license from package.json of internal apps &…
Elessar1802 c216503
chore: revert target url in vite.config.mts
Elessar1802 52142a9
fix(eslint): unable to find tsconfig.json
Elessar1802 edea433
chore: add compile command to root package.json
Elessar1802 1830b80
fix: use resolve to get lib paths in vite.config.mts
Elessar1802 7e428f3
chore: remove unneeded ci-workflows
Elessar1802 3a25c22
.
Elessar1802 e223932
fix: change import style for devtron-fe-lib
Elessar1802 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,8 @@ | ||
node_modules/ | ||
README.md | ||
.github | ||
.husky | ||
.lintstagedrc | ||
LICENSE | ||
.vscode/ | ||
.prettierrc.js |
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
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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
FROM node:20-alpine AS builder | ||
ENV PNPM_HOME="/pnpm" | ||
ENV PATH="$PNPM_HOME:$PATH" | ||
RUN corepack enable | ||
|
||
WORKDIR /app | ||
eshankvaish marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
COPY . . | ||
|
||
RUN echo `git rev-parse --short HEAD` > health.html | ||
|
||
RUN if [ -d "./devtron-fe-lib" ]; then rm -rf packages/devtron-fe-lib; cp -r ./devtron-fe-lib packages/devtron-fe-lib; fi | ||
|
||
RUN pnpm i | ||
RUN pnpm run build:prod | ||
eshankvaish marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
FROM nginx:stable | ||
|
||
RUN useradd -ms /bin/bash devtron | ||
|
||
COPY --from=builder /app/apps/web/dist/ /usr/share/nginx/html | ||
COPY --from=builder /app/apps/web/nginx.conf /etc/nginx/nginx.conf | ||
COPY --from=builder /app/apps/web/nginx-default.conf /etc/nginx/conf.d/default.conf | ||
|
||
WORKDIR /usr/share/nginx/html | ||
COPY --from=builder /app/apps/web/./env.sh . | ||
COPY --from=builder /app/apps/web/.env . | ||
COPY --from=builder /app/health.html . | ||
|
||
RUN chown -R devtron:devtron /usr/share/nginx/html | ||
# Make our shell script executable | ||
RUN chmod +x env.sh | ||
USER devtron | ||
CMD ["/bin/bash", "-c", "/usr/share/nginx/html/env.sh && nginx -g \"daemon off;\""] |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,158 @@ | ||
{ | ||
"name": "web", | ||
"version": "0.2.0", | ||
"private": true, | ||
"homepage": "/dashboard", | ||
"dependencies": { | ||
"@devtron-labs/devtron-fe-common-lib": "workspace:*", | ||
"@devtron-labs/devtron-fe-lib": "workspace:*", | ||
"@esbuild-plugins/node-globals-polyfill": "0.2.3", | ||
"@rjsf/core": "^5.13.3", | ||
"@rjsf/utils": "^5.13.3", | ||
"@rjsf/validator-ajv8": "^5.13.3", | ||
"@sentry/browser": "7.50.0", | ||
"@sentry/integrations": "7.50.0", | ||
"@sentry/tracing": "7.50.0", | ||
"@tippyjs/react": "4.2.6", | ||
"@typeform/embed-react": "2.20.0", | ||
"@types/marked": "4.0.8", | ||
"@vitejs/plugin-react": "4.3.1", | ||
"command-line-parser": "^0.2.10", | ||
"compute-histogram": "^0.9.11", | ||
"dayjs": "^1.11.8", | ||
"dompurify": "^3.0.2", | ||
"fast-json-patch": "^3.1.1", | ||
"flexsearch": "^0.6.32", | ||
"jsonpath-plus": "^9.0.0", | ||
"marked": "4.3.0", | ||
"moment": "^2.29.4", | ||
"monaco-editor": "0.44.0", | ||
"monaco-yaml": "5.1.1", | ||
"query-string": "^7.1.1", | ||
"react": "^17.0.2", | ||
"react-csv": "^2.2.2", | ||
"react-dates": "^21.8.0", | ||
"react-dom": "^17.0.2", | ||
"react-draggable": "^4.4.5", | ||
"react-ga4": "^1.4.1", | ||
"react-gtm-module": "^2.0.11", | ||
"react-keybind": "^0.9.4", | ||
"react-mde": "^11.5.0", | ||
"react-monaco-editor": "^0.55.0", | ||
"react-router-dom": "^5.3.4", | ||
"react-select": "5.8.0", | ||
"react-virtualized": "^9.22.5", | ||
"recharts": "^2.1.9", | ||
"rollup-plugin-node-polyfills": "0.2.1", | ||
"rxjs": "^7.5.4", | ||
"sockjs-client": "1.6.1", | ||
"tippy.js": "^6.3.7", | ||
"vite": "5.4.6", | ||
"vite-plugin-require-transform": "1.0.21", | ||
"vite-plugin-svgr": "^2.4.0", | ||
"xterm": "^4.19.0", | ||
"xterm-addon-fit": "^0.5.0", | ||
"xterm-addon-search": "^0.9.0", | ||
"xterm-webfont": "^2.0.0", | ||
"yaml": "^2.4.1" | ||
}, | ||
"scripts": { | ||
"lint": "tsc --noEmit && eslint 'src/**/*.{js,jsx,ts,tsx}' --max-warnings 0", | ||
"lint-fix": "eslint 'src/**/*.{js,jsx,ts,tsx}' --fix", | ||
"start": "vite --open", | ||
"build": "NODE_OPTIONS=--max_old_space_size=4096 vite build --sourcemap", | ||
"serve": "vite preview", | ||
"build-light": "NODE_OPTIONS=--max_old_space_size=4096 GENERATE_SOURCEMAP=false vite build", | ||
"build-k8s-app": "NODE_OPTIONS=--max_old_space_size=4096 GENERATE_SOURCEMAP=false VITE_K8S_CLIENT=true vite build", | ||
"test": "vitest test", | ||
"test-coverage:watch": "npm run test -- --coverage", | ||
"test-coverage": "npm run test -- --coverage --watchAll=false", | ||
"test:ci": "jest --watchAll=false --ci --json --coverage --testLocationInResults --outputFile=report.json", | ||
"jest": "jest", | ||
"storybook": "IS_STORYBOOK=true storybook dev -p 6006", | ||
"build-storybook": "IS_STORYBOOK=true storybook build" | ||
}, | ||
"browserslist": [ | ||
">0.2%", | ||
"not dead", | ||
"not ie <= 11", | ||
"not op_mini all" | ||
], | ||
"devDependencies": { | ||
"@chromatic-com/storybook": "^1.8.0", | ||
"@playwright/test": "^1.32.1", | ||
"@sentry/cli": "^2.2.0", | ||
"@storybook/addon-a11y": "^8.2.9", | ||
"@storybook/addon-actions": "^8.2.9", | ||
"@storybook/addon-essentials": "^8.2.9", | ||
"@storybook/addon-interactions": "^8.2.9", | ||
"@storybook/addon-links": "^8.2.9", | ||
"@storybook/blocks": "^8.2.9", | ||
"@storybook/react": "^8.2.9", | ||
"@storybook/react-vite": "^8.2.9", | ||
"@storybook/test": "^8.2.9", | ||
"@testing-library/jest-dom": "^5.16.2", | ||
"@testing-library/react": "^12.1.4", | ||
"@types/jest": "^27.4.1", | ||
"@types/node": "20.11.0", | ||
"@types/react": "17.0.39", | ||
"@types/react-csv": "^1.1.3", | ||
"@types/react-dom": "17.0.13", | ||
"@types/react-router-dom": "^5.3.3", | ||
"@types/react-transition-group": "^4.4.4", | ||
"@types/recharts": "^1.8.23", | ||
"@types/recompose": "^0.30.10", | ||
"@typescript-eslint/eslint-plugin": "8.3.0", | ||
"@typescript-eslint/parser": "8.3.0", | ||
"env-cmd": "10.1.0", | ||
"eslint": "^8.56.0", | ||
"eslint-config-airbnb": "^19.0.4", | ||
"eslint-config-prettier": "^9.1.0", | ||
"eslint-import-resolver-typescript": "^3.6.1", | ||
"eslint-plugin-import": "^2.29.1", | ||
"eslint-plugin-jsx-a11y": "^6.8.0", | ||
"eslint-plugin-prettier": "^5.1.2", | ||
"eslint-plugin-react": "^7.33.2", | ||
"eslint-plugin-react-hooks": "^4.6.0", | ||
"eslint-plugin-storybook": "^0.8.0", | ||
"jest-extended": "^2.0.0", | ||
"jest-junit": "^13.0.0", | ||
"jsdom-worker": "^0.2.1", | ||
"mock-socket": "^9.2.1", | ||
"prettier": "^3.1.1", | ||
"react-test-render": "^1.1.2", | ||
"sass": "^1.69.7", | ||
"storybook": "^8.2.9", | ||
"ts-jest": "29.2.5", | ||
"ts-node": "10.9.2", | ||
"typescript": "5.5.4", | ||
"vite-plugin-pwa": "0.20.2", | ||
"vite-tsconfig-paths": "5.0.1", | ||
"vitest": "2.0.5", | ||
"workbox-core": "7.1.0", | ||
"workbox-navigation-preload": "7.1.0", | ||
"workbox-precaching": "7.1.0", | ||
"workbox-routing": "7.1.0", | ||
"workbox-strategies": "7.1.0", | ||
"workbox-window": "7.1.0", | ||
"worker-loader": "3.0.8" | ||
}, | ||
"jest": { | ||
"collectCoverageFrom": [ | ||
"**/*.{ts,tsx,js,jsx}", | ||
"!**/?(*.)+(mock).+(ts|js)", | ||
"!**/node_modules/**", | ||
"!**/coverage/**", | ||
"!**/serviceWorker.ts", | ||
"!**/index.tsx", | ||
"!**/setupProxy.js" | ||
], | ||
"setupFilesAfterEnv": [ | ||
"jest-extended" | ||
], | ||
"moduleNameMapper": { | ||
"monaco-editor": "<rootDir>/node_modules/react-monaco-editor", | ||
"monaco-yaml": "<rootDir>/node_modules/react-monaco-editor" | ||
} | ||
} | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.