FROM feat/787-migrate-memories-seeder TO development#800
FROM feat/787-migrate-memories-seeder TO development#800ryaneggz merged 7 commits intodevelopmentfrom
Conversation
Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📝 WalkthroughWalkthroughThe pull request updates the project to include the seeds directory in Docker container builds. Changes involve modifying .dockerignore and Dockerfile to preserve seeds during the build process, updating project metadata to reflect the feat/787-migrate-memories-seeder branch focus, and adding documentation of the new build approach. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
…file Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: im-an-ai-agent <im.an.ai.agent@gmail.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@backend/Dockerfile`:
- Around line 35-36: The Dockerfile currently copies seeds into the final image
(see COPY --from=builder /app /app) while the RUN find command only excludes
/app/seeds/* from deletion, leaving seed .py files (e.g., user_seeder.py) as
source in production; open a follow-up issue pinned to the upcoming version
milestone requiring either removal of /app/seeds/* during the final image build
or converting seed sources to compiled .pyc (or sealed data) in the builder
stage, add a CI check that verifies no .py files remain under /app/seeds in the
final image, and update the Dockerfile to implement the chosen fix (adjust the
RUN find or add a cleanup step) so the final image matches the .pyc-only policy.
| # Exclude migrations/ (Alembic requires .py) and seeds/ (seeders need .py source) | ||
| RUN find /app -type f -name "*.py" ! -path "/app/migrations/*" ! -path "/app/seeds/*" -delete |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
# First, locate and examine seed files
find backend/seeds -type f -name "*.py" 2>/dev/null | head -20Repository: ruska-ai/orchestra
Length of output: 121
🏁 Script executed:
# Search for common secret/credential patterns in seed files
if [ -d "backend/seeds" ]; then
echo "=== Searching for credential patterns in seed files ==="
rg -nH -i \
-e 'password\s*=' \
-e 'secret\s*=' \
-e 'token\s*=' \
-e 'api_key\s*=' \
-e 'passw[a-z]*\s*=' \
-e 'default.*pass' \
-e 'hardcoded' \
-e '\bPII\b' \
backend/seeds
else
echo "backend/seeds directory not found"
fiRepository: ruska-ai/orchestra
Length of output: 317
🏁 Script executed:
# Check the Dockerfile to confirm the COPY logic mentioned in review
if [ -f "backend/Dockerfile" ]; then
echo "=== Checking COPY commands in Dockerfile ==="
grep -n "COPY.*builder" backend/Dockerfile
echo ""
echo "=== Full Dockerfile for context ==="
cat -n backend/Dockerfile
fiRepository: ruska-ai/orchestra
Length of output: 2645
🏁 Script executed:
# Search for any GitHub issues, TODOs, or tracking for seed removal
echo "=== Searching for seed removal tracking ==="
rg -i -n 'seed.*remov|remov.*seed|tech.*debt.*seed|seed.*deprecat' \
--type md --type txt --type py --type yaml --type yml \
. 2>/dev/null | head -20Repository: ruska-ai/orchestra
Length of output: 105
Seeds .py in production image — lacks removal tracking, but risk is lower than initially framed.
The find pattern is correct and seeds are confirmed in the final image via COPY --from=builder /app /app (line 57). However, the security risk is less severe than stated:
- Actual contents:
user_seeder.pycontains test user credentials with hashed passwords (test1234), not plaintext secrets or API keys. The hashing mitigates direct exposure. - Real concern: Seeds remain as readable
.pysource in production, inconsistent with the.pyc-only approach for the rest of the app. While test data is acceptable, this breaks the obfuscation model. - Tracking gap confirmed: No issue, CI gate, or milestone target for seed removal. This drift risk is valid and should be addressed.
Open a follow-up issue pinned to a specific version milestone to enforce seeds removal (or conversion to .pyc + sealed data) before this becomes permanent.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@backend/Dockerfile` around lines 35 - 36, The Dockerfile currently copies
seeds into the final image (see COPY --from=builder /app /app) while the RUN
find command only excludes /app/seeds/* from deletion, leaving seed .py files
(e.g., user_seeder.py) as source in production; open a follow-up issue pinned to
the upcoming version milestone requiring either removal of /app/seeds/* during
the final image build or converting seed sources to compiled .pyc (or sealed
data) in the builder stage, add a CI check that verifies no .py files remain
under /app/seeds in the final image, and update the Dockerfile to implement the
chosen fix (adjust the RUN find or add a cleanup step) so the final image
matches the .pyc-only policy.
Summary
Resolves #787
Include the
seeds/directory in the Docker container build so the memory seeder can be run from deployed environments.Status
Pipeline in progress — this PR will be marked ready for review when Ralph completes.
Generated by /feature-dev skill.
Summary by CodeRabbit