docs(ops): 実効env確認の pid 取得を pgrep から pm2 jlist へ是正 - #9
Merged
Merged
Conversation
pgrep -f 'toolify.*server.js' は ssh で送った自分のコマンド文字列に 先当たりし、無関係プロセス(bash -c ...)の environ を読んで NODE_OPTIONS=300 という誤答を返していた。VPS 上で再現確認済み (pgrep が返すのは自分自身の pid のみ、本体 3950723 は含まれない)。 pm2 jlist の JSON から name=="toolify" の pid をキーで取り出す方式に変更。 実測で PORT=8500 / HOSTNAME=toolify365.com / heap=400 を正しく返すことを確認。 Claude-Session: https://claude.ai/code/session_01ENHPNZ5ngcdrTHJ2H6oAFd
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.
docs/DEPLOY.md(5) の検証コマンドを是正する。pgrep -f 'toolify.*server.js'は ssh で送った自分のコマンド文字列に先当たりし、無関係プロセスの environ を読んで誤答を返す(実測: heap=300。本物は 3950723 / 実効 400)。
pid は綴りマッチでなく
pm2 jlistの JSON からキーで取り出す。VPS で実測して確認済み: PID 3950723 / PORT=8500 / HOSTNAME=toolify365.com / heap=400。
PR#8 を畳んでこちらに差し替えた理由
PR#7 が squash merge されたため PR#8 のブランチは未 squash の同内容コミットを抱え、
docs/DEPLOY.mdがコンフリクトしていた。さらに当該ブランチは main より古く、そのまま merge すると直前にデプロイした SEO 修正 (a1d0c90) を巻き戻す差分を含んでいた。
そこで現在の main の上に pid 修正のみ (b90e84b) を cherry-pick し直した。
main との差分は
docs/DEPLOY.mdの1ファイルのみ。ドキュメントのみの変更でコードに影響はない。
https://claude.ai/code/session_01ENHPNZ5ngcdrTHJ2H6oAFd