-
Notifications
You must be signed in to change notification settings - Fork 3.5k
refactor: update paths and structure for server services in Docker and documentation #7333
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…d documentation - Changed references from 'apiserver' to 'apps/server' in Docker configurations and environment setup. - Updated contributing documentation to reflect the new service structure. - Adjusted setup script to accommodate the new directory layout. - Removed obsolete files related to the previous structure.
WalkthroughThe changes update the project structure by renaming references from Changes
Sequence Diagram(s)sequenceDiagram
participant Dev as Developer
participant Script as setup.sh
participant EnvFile as apps/server/.env
Dev->>Script: Run setup.sh
Script->>EnvFile: Check for .env file existence
alt .env missing
Script->>EnvFile: Copy .env.example to .env
end
Script->>EnvFile: Check for SECRET_KEY
alt SECRET_KEY missing
Script->>EnvFile: Generate and append SECRET_KEY
end
Script-->>Dev: Output success message with new path
Possibly related PRs
Suggested reviewers
Poem
✨ Finishing Touches
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. 🪧 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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
🔭 Outside diff range comments (2)
docker-compose-local.yml (1)
19-25: plane-mq still consumes the wrong env file
env_file: - .envwas not updated during the refactor, but allRABBITMQ_*variables now reside in./apps/server/.env.
See ENV_SETUP.md lines 79-85.
Container boot will therefore miss its credentials. Point to the correct file or relocate the variables.setup.sh (1)
63-78: Avoid duplicating SECRET_KEY entriesThe script blindly appends a new
SECRET_KEYevery run. Re-runningsetup.shwill accumulate keys and Django will read only the first one, confusing future debugging.Guard with a grep:
-if [ -f "./apps/server/.env" ]; then +if [ -f "./apps/server/.env" ]; then + if ! grep -q '^SECRET_KEY=' ./apps/server/.env; then echo -e "SECRET_KEY=\"$SECRET_KEY\"" >> ./apps/server/.env echo -e "${GREEN}✓${NC} Added SECRET_KEY to apps/server/.env" + else + echo -e "${BLUE}i${NC} SECRET_KEY already present in apps/server/.env" + fi
🧹 Nitpick comments (5)
CONTRIBUTING.md (1)
186-202: Fix markdown-lint warning by using fenced code blocks
markdownlint(MD046) still reports “indented” code blocks around these lines. Replace the four-space-indented blocks with fenced blocks (```ts/```) to silence CI:- // types/language.ts - export type TLanguage = "en" | "fr" | "your-lang"; +```typescript +// types/language.ts +export type TLanguage = "en" | "fr" | "your-lang"; +```Repeat for the other two indented snippets.
aio/Dockerfile-app (1)
73-85: Path updates are correct but you can collapse COPY layersAll COPY instructions were updated to
apps/server, 👍.
To reduce image layer count and leverage Docker cache you could merge them:-COPY apps/server/requirements.txt ./api/ -COPY apps/server/requirements ./api/requirements -… -COPY apps/server/manage.py ./api/manage.py -COPY apps/server/plane ./api/plane/ -COPY apps/server/templates ./api/templates/ -… -COPY apps/server/bin ./api/bin/ +COPY apps/server/ \ + ./api/ \ + --chmod=0755Not mandatory, but it speeds up incremental builds.
.github/workflows/build-test-pull-request.yml (1)
18-21: Label says “Install Pylint” but installs RuffRename the step for clarity:
- - name: Install Pylint + - name: Install RuffPurely cosmetic but avoids confusion for maintainers reading job logs.
ENV_SETUP.md (2)
31-33: Remove leftover deprecated variable to avoid confusion
DOCKERIZED=1is still documented here even though the comment marks it as deprecated and the rest of the refactor explicitly removes any need for it. Leaving it in the sample root.envencourages cargo-cult copy-pasting and increases the number of divergent configuration states we must support.
Recommend deleting it entirely (or moving it to a historical changelog section).
86-90: Avoid committing real-looking secretsThe sample shows a concrete
SECRET_KEYvalue. Even if it’s only an example, downstream users (and automated scripts) tend to reuse it, which defeats the purpose of the key.
Prefer a placeholder such asCHANGE_MEor instruct users to runsetup.shto generate a unique key instead.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (11)
.github/workflows/build-test-pull-request.yml(2 hunks)CONTRIBUTING.md(6 hunks)ENV_SETUP.md(2 hunks)aio/Dockerfile-app(1 hunks)apps/server/Procfile(0 hunks)apps/server/runtime.txt(0 hunks)deploy/selfhost/build.yml(1 hunks)docker-compose-local.yml(2 hunks)docker-compose.yml(3 hunks)heroku.yml(0 hunks)setup.sh(2 hunks)
💤 Files with no reviewable changes (3)
- apps/server/runtime.txt
- heroku.yml
- apps/server/Procfile
🧰 Additional context used
🧠 Learnings (1)
CONTRIBUTING.md (2)
Learnt from: janreges
PR: makeplane/plane#6743
File: packages/i18n/src/store/index.ts:160-161
Timestamp: 2025-03-11T19:42:41.769Z
Learning: In the Plane project, the file 'packages/i18n/src/store/index.ts' already includes support for Polish language translations with the case "pl".
Learnt from: vamsikrishnamathala
PR: makeplane/plane#7092
File: web/core/components/issues/issue-detail-widgets/sub-issues/issues-list/root.tsx:109-113
Timestamp: 2025-05-22T11:21:49.370Z
Learning: Both translation keys "sub_work_item.empty_state.list_filters.action" and "sub_work_item.empty_state.sub_list_filters.action" have identical values across all language files in the Plane project, so they can be used interchangeably.
🪛 markdownlint-cli2 (0.17.2)
CONTRIBUTING.md
189-189: Code block style
Expected: fenced; Actual: indented
(MD046, code-block-style)
197-197: Code block style
Expected: fenced; Actual: indented
(MD046, code-block-style)
215-215: Code block style
Expected: fenced; Actual: indented
(MD046, code-block-style)
🔇 Additional comments (4)
CONTRIBUTING.md (1)
51-52: Backend path reference corrected – looks goodThe switch from
apiservertoapps/serveraligns with the new directory layout used throughout the PR.docker-compose.yml (1)
40-52: API service adjustments checkedThe context and env-file updates to
apps/serverare consistent with the repo restructure, and the compose file sits at repo root so the new relative paths resolve correctly.docker-compose-local.yml (2)
125-137: Path updates look consistentBuild context, volume mounts and
env_filepaths were correctly switched fromapiservertoapps/server.
No functional concerns here.Also applies to: 145-158, 165-177, 183-195
195-196: Migrator now sources the root .env onlyUnlike the other backend services,
migratorwas changed to read the root.env.
Check that every setting it needs (e.g.SECRET_KEY,RABBITMQ_*, any Django-specific toggles) is present there; otherwise migrations may fail in CI/CD while working locally.
…d documentation (#7333) - Changed references from 'apiserver' to 'apps/server' in Docker configurations and environment setup. - Updated contributing documentation to reflect the new service structure. - Adjusted setup script to accommodate the new directory layout. - Removed obsolete files related to the previous structure.
Description
Type of Change
Test Scenarios
References
Summary by CodeRabbit
apps/serverpath across configuration, Docker, and setup files.