Skip to content

docs: adapt for the new start script#768

Open
Stream29 wants to merge 2 commits intomainfrom
feat/easier-simpler-deploy
Open

docs: adapt for the new start script#768
Stream29 wants to merge 2 commits intomainfrom
feat/easier-simpler-deploy

Conversation

@Stream29
Copy link
Copy Markdown

No description provided.

@Stream29 Stream29 requested a review from RiskeyL as a code owner April 29, 2026 21:01
Copilot AI review requested due to automatic review settings April 29, 2026 21:01
@mintlify
Copy link
Copy Markdown
Contributor

mintlify Bot commented Apr 29, 2026

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
dify-core-product 🟢 Ready View Preview Apr 29, 2026, 9:03 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Apr 29, 2026
@dosubot dosubot Bot added the documentation Improvements or additions to documentation label Apr 29, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the self-hosting documentation to reflect using the new Docker Compose “wrapper” start script instead of calling Docker Compose directly.

Changes:

  • Replace manual .env copy + docker compose up instructions with dify-compose / dify-compose.ps1 wrapper commands.
  • Update environment variable reference to reflect wrapper-generated SECRET_KEY.
  • Document MAIL_TYPE as optional (empty disables email sending).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
en/self-host/quick-start/docker-compose.mdx Switch quick-start commands to the new compose wrapper and update restart/upgrade guidance.
en/self-host/configuration/environments.mdx Adjust documented defaults/behavior for SECRET_KEY and MAIL_TYPE, plus minor formatting.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +56 to +62
<Note>
The wrapper creates `.env` if one does not exist and writes a generated `SECRET_KEY` to it. Press Enter to use the default deployment, or answer `y` to edit `.env` first. Use `.env.example` as the full environment variable reference.

<Tip>
Run `docker compose version` to check your Docker Compose version.
</Tip>
When the frontend and backend run on different subdomains, set `COOKIE_DOMAIN` to the site's top-level domain (e.g., `example.com`) and set `NEXT_PUBLIC_COOKIE_DOMAIN` to `1` in the `.env` file.

The frontend and backend must be under the same top-level domain to share authentication cookies.
</Note>
Copy link

Copilot AI Apr 29, 2026

Choose a reason for hiding this comment

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

The note says to use .env.example as the environment variable reference, but later the upgrade guidance tells users to review changes to .env.default as well. This introduces a new file concept without explaining what .env.default is (baseline defaults vs. example reference) or how users should merge/override values between .env.default, .env.example, and their local .env. Consider briefly defining each file’s role here and recommending a single upgrade workflow (e.g., which files to diff/compare, and whether .env should contain only overrides plus the generated SECRET_KEY).

Copilot uses AI. Check for mistakes.
|---|---|---|
| `MAIL_TYPE` | `resend` | Mail provider: `resend`, `smtp`, or `sendgrid`. |
| `MAIL_TYPE` | (empty) | Mail provider: `resend`, `smtp`, or `sendgrid`. Leave empty to disable email sending. |
| `MAIL_DEFAULT_SEND_FROM` | (empty) | Default "From" address for all outgoing emails. Required. |
Copy link

Copilot AI Apr 29, 2026

Choose a reason for hiding this comment

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

MAIL_TYPE is now documented as optional/empty to disable email sending, but MAIL_DEFAULT_SEND_FROM is still described as “Required.” This is ambiguous—if email is disabled, it likely shouldn’t be required. Suggest clarifying that MAIL_DEFAULT_SEND_FROM is required only when MAIL_TYPE is set (and possibly per-provider requirements), or otherwise explain why it must always be set even when MAIL_TYPE is empty.

Suggested change
| `MAIL_DEFAULT_SEND_FROM` | (empty) | Default "From" address for all outgoing emails. Required. |
| `MAIL_DEFAULT_SEND_FROM` | (empty) | Default "From" address for all outgoing emails. Required when `MAIL_TYPE` is set. |

Copilot uses AI. Check for mistakes.
Comment on lines +144 to +146
Default: generated into `.env` by the Docker Compose wrapper.

Used for session cookie signing, JWT authentication tokens, file URL signatures (HMAC-SHA256), and encrypting third-party OAuth credentials (AES-256). Generate a strong key before first launch:
Used for session cookie signing, JWT authentication tokens, file URL signatures (HMAC-SHA256), and encrypting third-party OAuth credentials (AES-256). The Docker Compose wrapper generates a strong key before first launch. For manual deployments, generate one with:
Copy link

Copilot AI Apr 29, 2026

Choose a reason for hiding this comment

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

This update changes the documented defaults/behavior for SECRET_KEY (generated by wrapper) and MAIL_TYPE (empty disables email) in English, but the corresponding JA/ZH environment docs still describe the previous defaults (e.g., JA/ZH SECRET_KEY says pre-filled in .env.example; JA/ZH MAIL_TYPE default resend). To avoid inconsistent guidance across locales, please update the translated pages (e.g., ja/self-host/configuration/environments.mdx around the SECRET_KEY section and mail table, and the same sections in zh/...).

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Copy Markdown
Contributor

🌐 Multi-language Sync

✅ Created sync PR #769

Synced 2 files to cn + jp

Both PRs can merge independently. Future commits here will auto-update the sync PR.

…eploy

# Conflicts:
#	en/self-host/quick-start/docker-compose.mdx
@dosubot dosubot Bot added size:L This PR changes 100-499 lines, ignoring generated files. and removed size:M This PR changes 30-99 lines, ignoring generated files. labels May 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants