Fix env path - #110
Conversation
WalkthroughThe updates introduce improved environment variable management by updating example files, removing sensitive Changes
Sequence Diagram(s)sequenceDiagram
participant Workflow
participant FileSystem
participant TestRunner
Workflow->>FileSystem: Copy .env.example to .env (in dox-app)
Workflow->>TestRunner: Run tests with DB_PORT/DB_USER env vars set
TestRunner->>FileSystem: Read .env for configuration
TestRunner->>Database: Connect using env-driven parameters
Poem
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
README.md (1)
4-6: Badge lacks an explicit anchor; users can’t click through reliablyThe
link=query param in the shields-io URL sometimes fails on GitHub’s markdown renderer.
Wrap the badge in a normal markdown link so the target is always reachable and screen-reader friendly.- +[](https://coderabbit.ai)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
.github/workflows/test.yaml(1 hunks).gitignore(1 hunks)README.md(1 hunks)melos.yaml(1 hunks)packages/dox-app/.env(0 hunks)packages/dox-app/.env.example(1 hunks)packages/dox-query-builder/test/connection.dart(2 hunks)
💤 Files with no reviewable changes (1)
- packages/dox-app/.env
🧰 Additional context used
🪛 Gitleaks (8.26.0)
packages/dox-app/.env.example
4-4: Detected a Generic API Key, potentially exposing access to various services and sensitive operations.
(generic-api-key)
🔇 Additional comments (6)
.gitignore (1)
10-11:.envpattern ignores all nested.envfiles – is that intentional?A bare
.enventry matches every file named.envanywhere in the tree, not just the repo root.
If package-level.envfiles are created locally (e.g. during tests) they’ll be un-tracked too, which might hide accidental commits of secrets.Confirm that this broad ignore is desired; otherwise scope it:
-.env +/packages/*/.env +/.envpackages/dox-app/.env.example (1)
13-14: Nice addition of Redis defaultsThe new
REDIS_HOST/REDIS_PORTvariables complete the sample config and remove a common gotcha for first-time setup. 👍.github/workflows/test.yaml (1)
62-70: MySQL test step lacksDB_PASSWORD; may fail when auth is enforced
packages/dox-query-builder/test/connection.dartnow readsDB_PASSWORD(falls back to'password'only if env var absent?).
Because the MariaDB service is started withMYSQL_PASSWORD: password, propagate the same value to ensure deterministic CI:- run: DB_USER=dox DB_PORT=3306 melos test_query_builder_mysql + run: DB_USER=dox DB_PASSWORD=password DB_PORT=3306 melos test_query_builder_mysqlPlease verify the test still passes locally.
melos.yaml (1)
11-13: Config tweak looks correctSwitching
ignoreto a list and settingnoSelect: truematches the melos schema and avoids interactive prompts during CI. No further action required.packages/dox-query-builder/test/connection.dart (2)
27-27: Verify the dramatic reduction in maxConnectionAge.The
maxConnectionAgewas reduced from 1 hour to 500 milliseconds, which is a significant change that could impact performance by causing frequent connection recycling.Please confirm this change is intentional and verify that it doesn't negatively impact test performance or connection stability.
39-39: Good improvement for configurability.Making the MySQL user configurable via environment variable is a good improvement for flexibility and security.
Summary by CodeRabbit
Chores
Documentation
Bug Fixes