Add Custom Domains + SMTP migration wizard support#3057
Conversation
Adds api-key as a child toggle under the existing integrations group, matching the parent-child pattern used by users/teams, databases/rows, and messaging/messages. The backend uses the kebab-case 'api-key' resource id; the form field stays camelCase as a local property.
Adds new 'settings' form group (parent for project-level configuration like variables and webhooks). Project variables become settings.root. The backend migration library exposes them via the new GROUP_SETTINGS.
Adds webhook as a child toggle under the existing settings group, joining project variables as the second project-level setting that can be migrated.
- MigrationResource union + MigrationResources enum gain 'auth-methods' - New top-level form group 'authMethods' (root-only, like backups) - providerResources.appwrite includes AuthMethods - migrationFormToResources / resourcesToMigrationForm round-trip - resource-form.svelte shouldRenderGroup + getReportKey - importReport.svelte labelMap + descriptionMap
Greptile SummaryThis PR adds Custom Domains (
Confidence Score: 3/5Safe to merge once the SMTP/custom-domain description visibility issue is resolved — users currently cannot see the important caveats (password not migrated, auto-domains skipped) before selecting those checkboxes. The core store and resource-mapping logic is well-structured and symmetric. The main concern is in importReport.svelte: descriptions written for root-only groups like smtp and customDomains are never passed to the Selector.Checkbox and therefore never shown to users. These descriptions carry migration-critical information — notably that the SMTP password is not transferred and that .appwrite.network auto-domains are silently skipped. importReport.svelte — the no-children checkbox rendering path needs to surface the root description to users. Important Files Changed
|
| if (resources.includes(MigrationResources.ApiKey)) { | ||
| formData.integrations.root = true; | ||
| formData.integrations.apiKeys = true; | ||
| } | ||
| if (resources.includes(MigrationResources.ProjectVariable)) { | ||
| formData.settings.root = true; | ||
| } | ||
| if (resources.includes(MigrationResources.Webhook)) { | ||
| formData.settings.root = true; | ||
| formData.settings.webhooks = true; | ||
| } |
There was a problem hiding this comment.
Round-trip inconsistency: sub-item presence sets
root=true, which forward-maps to the parent resource
When resourcesToMigrationForm is called with a list that contains ApiKey but not Platform, it sets formData.integrations.root = true. Then migrationFormToResources always emits Platform when integrations.root is true, so a round-trip silently adds Platform to the resource list. The same applies to Webhook / ProjectVariable in the settings group.
In the current UI flow resourcesToMigrationForm is only called via selectAll() with the full provider list (which always includes both resources), so this is not immediately observable. However, if the function is reused in an edit/re-import flow in the future, migrations could silently acquire unintended resources.
Summary
Custom domainsandCustom SMTProws to the migration wizard's resource picker.Pairs with:
Test plan