Skip to content

refactor(forgeCLI): improve logging and process validation for PocketBase#61

Merged
melvinchia3636 merged 3 commits intomainfrom
fix/dbinit
Jan 1, 2026
Merged

refactor(forgeCLI): improve logging and process validation for PocketBase#61
melvinchia3636 merged 3 commits intomainfrom
fix/dbinit

Conversation

@lukashow
Copy link
Copy Markdown
Collaborator

@lukashow lukashow commented Jan 1, 2026

This is part of the fix of #60

tidr: This fix implements better pocketbase process detection using ps instead of pgrep (due to issues in Linux that causing "weird spawning" pocketbase process out from nowhere.


This pull request improves the reliability and clarity of the PocketBase server management logic in the Forge CLI. The main focus is on making the detection of running PocketBase processes more robust and providing clearer messaging to users during database setup.

Improvements to PocketBase process detection:

  • Added a new helper function isValidPocketbaseProcess to verify that a detected PID is actually a running PocketBase process by checking the command name, reducing the risk of false positives.
  • Updated checkRunningPBInstances to use the new validation logic, handle multiple PIDs, and improve error messages by listing all detected PocketBase process IDs.

User messaging enhancements:

  • Combined and clarified the completion message in initializeDatabaseHandler to inform users in a single step that setup is complete and how to start the PocketBase server.

@github-actions
Copy link
Copy Markdown

github-actions bot commented Jan 1, 2026

🔨 Build Results

Backend Build: Passed
Frontend Build: Passed

🎉 All builds completed successfully!

🔗 View full workflow run

melvinchia3636
melvinchia3636 previously approved these changes Jan 1, 2026
Copy link
Copy Markdown
Member

@melvinchia3636 melvinchia3636 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@vercel
Copy link
Copy Markdown

vercel bot commented Jan 1, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Review Updated (UTC)
lifeforge-ui Ignored Ignored Jan 1, 2026 3:14pm

Copy link
Copy Markdown
Member

@melvinchia3636 melvinchia3636 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Copy Markdown
Member

@melvinchia3636 melvinchia3636 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM on behalf of lukas

@lukashow
Copy link
Copy Markdown
Collaborator Author

lukashow commented Jan 1, 2026

LGTM

@melvinchia3636 melvinchia3636 merged commit 9926f04 into main Jan 1, 2026
6 checks passed
@melvinchia3636 melvinchia3636 deleted the fix/dbinit branch January 1, 2026 15:16
@melvinchia3636 melvinchia3636 added bug Something isn't working as expected enhancement New feature or request labels Jan 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working as expected enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants