Open dgtn-va opened 12 months ago
Hi, @dgtn-va , Thanks for your report, I added a document here : https://tianji.msgbyte.com/docs/install/manual
can you help us test it? if you have any problem, i can help you resolve it and improve this document
Thank you very much!
I plan this and I will come back soon with my feedback ;)
Hey @moonrailgun I noticed that the usage seemed way higher when building from source and running it locally then running it inside a docker container.
Is this sort of behavior expected?
@moonrailgun Hi,
During my first test install, I had to add (globally) some missing dependencies for pnpm install
:
After all clear and fresh restart:
pnpm install
: PASSpnpm build
: FAILActually, I can't run preconized 18.0 (pnpm requiere 18.12 minimum) or 20.4 (not available for me) Node.js versions. I can only these 20.x versions: 20.0.0, 20.1.0, 20.3.1, 20.7.0, 20.9.0, 20.11.0, 20.11.1, 20.13.1. Or 18.x versions: 18.0.0, 18.1.0, 18.5.0, 18.9.1, 18.12.1, 18.13.0, 18.15.0, 18.16.0, 18.16.1, 18.18.0, 18.18.2, 18.19.0, 18.19.1, 18.20.2.
But same result for tested version 20.7.0, 20.13.1 or 18.12.1...
dgtn-va@ssh1:~/tianji$ pnpm install
Scope: all 7 workspace projects Lockfile is up to date, resolution step is skipped Packages: +2840 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Progress: resolved 2840, reused 2765, downloaded 0, added 2840, done node_modules/.pnpm/@prisma+engines@4.16.2/node_modules/@prisma/engines: Running postinstall script, done in 2s node_modules/.pnpm/@prisma+engines@5.4.2/node_modules/@prisma/engines: Running postinstall script, done in 2.1s node_modules/.pnpm/esbuild@0.20.1/node_modules/esbuild: Running postinstall script, done in 416ms node_modules/.pnpm/esbuild@0.19.11/node_modules/esbuild: Running postinstall script, done in 399ms node_modules/.pnpm/msw@2.2.13_typescript@5.4.5/node_modules/msw: Running postinstall script, done in 107ms node_modules/.pnpm/isolated-vm@4.7.2/node_modules/isolated-vm: Running install script, done in 40.5s node_modules/.pnpm/puppeteer@21.7.0_typescript@5.4.5/node_modules/puppeteer: Running postinstall script, done in 18.2s node_modules/.pnpm/core-js-pure@3.36.0/node_modules/core-js-pure: Running postinstall script, done in 66ms node_modules/.pnpm/core-js@3.36.0/node_modules/core-js: Running postinstall script, done in 58ms node_modules/.pnpm/postman-code-generators@1.8.0/node_modules/postman-code-generators: Running postinstall script, done in 1m 8.4s node_modules/.pnpm/react-vertical-timeline-component@3.6.0_react@18.3.1/node_modules/react-vertical-timeline-component: Running postinstall script, done in 73ms node_modules/.pnpm/prisma@5.4.2/node_modules/prisma: Running preinstall script, done in 64ms node_modules/.pnpm/@prisma+client@4.16.2_prisma@5.4.2/node_modules/@prisma/client: Running postinstall script, done in 1.4s node_modules/.pnpm/@prisma+client@5.4.2_prisma@5.4.2/node_modules/@prisma/client: Running postinstall script, done in 1.4s
dependencies:
- dayjs 1.11.10
- eventemitter-strict 1.0.1
- zod 3.22.2
devDependencies:
- @release-it/conventional-changelog 8.0.1
- @types/fs-extra 11.0.3
- @types/node 18.17.12
- @types/tar 6.1.10
- concurrently 8.2.2
- cross-env 7.0.3
- fs-extra 11.2.0
- prettier-plugin-tailwindcss 0.5.12
- release-it 17.0.1
- tar 6.1.15
- ts-node 10.9.1
- typescript 5.2.2
- vite 5.0.12
src/shared postinstall$ pnpm build [12 lines collapsed] │ [build:cjs] npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.0 │ [build:cjs] npm notice Run
npm install -g npm@10.8.0
to update! │ [build:cjs] npm notice │ [build:esm] npm notice │ [build:esm] npm notice New major version of npm available! 9.9.3 -> 10.8.0 │ [build:esm] npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.0 │ npm notice Runnpm install -g npm@10.8.0
to update! │ [build:esm] npm notice │ [build:cjs] npm run build:cjs exited with code 0 │ [build:esm] npm run build:esm exited with code 0 └─ Done in 4.7s packages/client-sdk prepare$ tsc └─ Done in 2.8s packages/react prepare$ tsc └─ Done in 1.6s src/server postinstall$ pnpm db:generate [7 lines collapsed] ││ import { PrismaClient } from '@prisma/client' │ const prisma = new PrismaClient() │
│ or start using Prisma Client at the edge (See: https://pris.ly/d/accelerate) ││ import { PrismaClient } from '@prisma/client/edge' │ const prisma = new PrismaClient() │
│ See other ways of importing Prisma Client: http://pris.ly/d/importing-client └─ Done in 5.3s Done in 3m 24.2s
dgtn-va@ssh1:~/tianji$ pnpm build
tianji@1.11.1 build /home/dgtn-va/tianji pnpm build:tracker && pnpm build:app && pnpm build:geo
tianji@1.11.1 build:tracker /home/dgtn-va/tianji ts-node scripts/build-tracker.ts
The CJS build of Vite's Node API is deprecated. See https://vitejs.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details. Start Build Tracker vite v5.0.12 building for production... ✓ 1 modules transformed. src/client/public/tracker.js 2.52 kB │ gzip: 1.45 kB ✓ built in 265ms Build Tracker Completed
tianji@1.11.1 build:app /home/dgtn-va/tianji pnpm build:server && pnpm build:client
tianji@1.11.1 build:server /home/dgtn-va/tianji cd src/server && pnpm build
@tianji/server@1.0.0 build /home/dgtn-va/tianji/src/server tsc -p tsconfig.server.json
tianji@1.11.1 build:client /home/dgtn-va/tianji cd src/client && pnpm build
@tianji/client@ build /home/dgtn-va/tianji/src/client vite build
♻️ Generating routes... ✅ Processed routes in 4825ms vite v5.0.12 building for production... ../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/index.module.js (1:1576) A comment
"/#PURE/"
in "../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/index.module.js" contains an annotation that Rollup cannot interpret due to the position of the comment. The comment w ill be removed to avoid issues. ../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/index.module.js (1:2992) A comment
"/#PURE/"
in "../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/index.module.js" contains an annotation that Rollup cannot interpret due to the position of the comment. The comment w ill be removed to avoid issues. Killed ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137. dgtn-va@ssh1:~/tianji$
About manual procedure install: https://tianji.msgbyte.com/docs/install/manual
connection_limit=10
param in your dist .env(.example) like described in your procedure.en_US.utf8
value or possibly something else? And some extensions needed too?Thanks.
thanks for your report. i will update document for your report.
let me know if still has error
Hey @moonrailgun I noticed that the usage seemed way higher when building from source and running it locally then running it inside a docker container.
did you full follow dockerfile to build frontend and server?
Hey @moonrailgun I noticed that the usage seemed way higher when building from source and running it locally then running it inside a docker container.
did you full follow dockerfile to build frontend and server?
Frontend and Server built locally
@moonrailgun
let me know if still has error
Thanks, but my last test has been runned on officially compatible env:
dgtn-va@ssh1: ~$ node -v v18.12.1 dgtn-va@ssh1: ~$ npm list -g --depth=0 npm notice npm notice New major version of npm available! 9.9.3 -> 10.8.0 npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.0 npm notice Run npm install -g npm@10.8.0 to update! npm notice /home/dgtn-va/.npm-packages/lib ├── npm@9.9.3 ├── pm2@5.3.1 ├── pnpm@9.1.2 ├── ts-node@10.9.2 └── typescript@5.4.5 digitanie@ssh1: ~$
Yet the build process unexpectedly stops... I don't see what the problem is.
Thank you.
i think you are using pnpm 9. but recommand to use pnpm@8
some break change but not time to upgrade yet.
Strictelly v8, okay.
For me, "+" suppose compatible with any superior versions, including majors. You sould be probably write pnpm@8
instead in the manual 😉
New test and exactlly same issue/exit with pnpm@8.15.8 🙁
dgtn-va@ssh1:~/tianji$ pnpm install
Scope: all 7 workspace projects Lockfile is up to date, resolution step is skipped Packages: +2840 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
╭─────────────────────────────────────────────────────────────────╮ │ │ │ Update available! 8.15.8 → 9.1.2. │ │ Changelog: https://github.com/pnpm/pnpm/releases/tag/v9.1.2 │ │ Run "pnpm add -g pnpm" to update. │ │ │ │ Follow @pnpmjs for updates: https://twitter.com/pnpmjs │ │ │ ╰─────────────────────────────────────────────────────────────────╯
Progress: resolved 2840, reused 2765, downloaded 0, added 2840, done node_modules/.pnpm/msw@2.2.13_typescript@5.4.5/node_modules/msw: Running postinstall script... node_modules/.pnpm/msw@2.2.13_typescript@5.4.5/node_modules/msw: Running postinstall script, done in 168msne-componen node_modules/.pnpm/react-vertical-timeline-component@3.6.0_react@18.3.1/node_modules/react-vertical-timeline-componen t: Running postinstall script, done in 137msdules/isolated-vm: Running install script... node_modules/.pnpm/isolated-vm@4.7.2/node_modules/isolated-vm: Running install script, done in 44.4snstall script... node_modules/.pnpm/postman-code-generators@1.8.0/node_modules/postman-code-generators: Running postinstall script, do ne in 1m 30.1s node_modules/.pnpm/esbuild@0.19.11/node_modules/esbuild: Running postinstall script, done in 477ms node_modules/.pnpm/esbuild@0.20.1/node_modules/esbuild: Running postinstall script, done in 465ms node_modules/.pnpm/prisma@5.4.2/node_modules/prisma: Running preinstall script, done in 94ms node_modules/.pnpm/@prisma+client@5.4.2_prisma@5.4.2/node_modules/@prisma/client: Running postinstall script... node_modules/.pnpm/@prisma+client@5.4.2_prisma@5.4.2/node_modules/@prisma/client: Running postinstall script, done in 2.1ss
node_modules/.pnpm/puppeteer@21.7.0_typescript@5.4.5/node_modules/puppeteer: Running postinstall script, done in 2.4s
dependencies:
- dayjs 1.11.10
- eventemitter-strict 1.0.1
- zod 3.22.2
devDependencies:
- @release-it/conventional-changelog 8.0.1
- @types/fs-extra 11.0.3
- @types/node 18.17.12
- @types/tar 6.1.10
- concurrently 8.2.2
- cross-env 7.0.3
- fs-extra 11.2.0
- prettier-plugin-tailwindcss 0.5.12
- release-it 17.0.1
- tar 6.1.15
- ts-node 10.9.1
- typescript 5.2.2
- vite 5.0.12
src/shared postinstall$ pnpm build [2 lines collapsed] │ [build:esm] │ [build:esm] > @tianji/shared@1.0.0 build:esm │ [build:esm] > tsc --module esnext --outDir ./dist/esm │ [build:esm] │ [build:cjs] │ [build:cjs] > @tianji/shared@1.0.0 build:cjs │ [build:cjs] > tsc --module commonjs --outDir ./dist/cjs │ [build:cjs] │ [build:esm] npm run build:esm exited with code 0 │ [build:cjs] npm run build:cjs exited with code 0 └─ Done in 7.6s packages/client-sdk prepare$ tsc └─ Done in 4.5s packages/react prepare$ tsc └─ Done in 2.4s src/server postinstall$ pnpm db:generate [7 lines collapsed] │
│ import { PrismaClient } from '@prisma/client' │ const prisma = new PrismaClient() │
│ or start using Prisma Client at the edge (See: https://pris.ly/d/accelerate) ││ import { PrismaClient } from '@prisma/client/edge' │ const prisma = new PrismaClient() │
│ See other ways of importing Prisma Client: http://pris.ly/d/importing-client └─ Done in 8.1s Done in 4m 53.4s
dgtn-va@ssh1:~/tianji$ pnpm build
tianji@1.11.1 build /home/dgtn-va/tianji pnpm build:tracker && pnpm build:app && pnpm build:geo
tianji@1.11.1 build:tracker /home/dgtn-va/tianji ts-node scripts/build-tracker.ts
The CJS build of Vite's Node API is deprecated. See https://vitejs.dev/guide/troubleshooting.html#vite-cjs-node-api-d eprecated for more details. Start Build Tracker vite v5.0.12 building for production... ✓ 1 modules transformed. src/client/public/tracker.js 2.52 kB │ gzip: 1.45 kB ✓ built in 139ms Build Tracker Completed
tianji@1.11.1 build:app /home/dgtn-va/tianji pnpm build:server && pnpm build:client
tianji@1.11.1 build:server /home/dgtn-va/tianji cd src/server && pnpm build
@tianji/server@1.0.0 build /home/dgtn-va/tianji/src/server tsc -p tsconfig.server.json
tianji@1.11.1 build:client /home/dgtn-va/tianji cd src/client && pnpm build
@tianji/client@ build /home/dgtn-va/tianji/src/client vite build
♻️ Generating routes... ✅ Processed routes in 4359ms vite v5.0.12 building for production... ../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/in dex.module.js (1:1576) A comment
"/#PURE/"
in "../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dis t/index.module.js" contains an annotation that Rollup cannot interpret due to the position of the comment. The commen t will be removed to avoid issues. ../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dist/in dex.module.js (1:2992) A comment
"/#PURE/"
in "../../node_modules/.pnpm/next-themes@0.2.1_next@14.1.3_react-dom@18.2.0_react@18.2.0/node_modules/next-themes/dis t/index.module.js" contains an annotation that Rollup cannot interpret due to the position of the comment. The commen t will be removed to avoid issues. ✓ 10852 modules transformed. Killed ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137. ELIFECYCLE Command failed with exit code 137.
dgtn-va@ssh1:~/tianji$
Thanks for your report.
i think exit code 137 means OOM error. its not recommend build frontend code in servers, special in low resource server.
for example, free github action even has 4gb memory for build.
actually, you can build tianji, then upload to server. i think its will be work fine in your case.
BTW, how much resource about your server?
Just installed Tianji without docker. Some adjustments have to be made.
9.5.0
npm install -g pnpm
[Source]{ name: "tianji", script: "dist/src/server/main.js", cwd: "/var/www/html/tianji/src/server/", watch: false, env: { "PORT": 3004, "NODE_ENV": "production" } }
as https://github.com/msgbyte/tianji/commit/1b89c3b5a808b57f1a695b86a8f35e4199e0ed7c the pnpm version is bumped to 9.5.0
thanks for reminder, i will update document.
Hi,
I would like install it on PaaS, where containerization is not available (because this env deploy with), like it's possible for Uptime Kuma. Alternative install/update method is planned in roadmap?
Thank you :)