From fa1663d8583be3930820caaf2954856b51b2b4f1 Mon Sep 17 00:00:00 2001 From: Victor Hugo dos Santos <115753265+victorvhs017@users.noreply.github.com> Date: Mon, 6 Oct 2025 03:40:06 -0300 Subject: [PATCH] docs: enhance file upload troubleshooting guidance in migration (#6645) Co-authored-by: pandeymangg --- apps/web/locales/de-DE.json | 2 + apps/web/locales/en-US.json | 2 + apps/web/locales/fr-FR.json | 2 + apps/web/locales/ja-JP.json | 2 + apps/web/locales/pt-BR.json | 2 + apps/web/locales/pt-PT.json | 2 + apps/web/locales/ro-RO.json | 2 + apps/web/locales/zh-Hans-CN.json | 2 + apps/web/locales/zh-Hant-TW.json | 2 + docs/self-hosting/advanced/migration.mdx | 2 +- .../configuration/file-uploads.mdx | 40 ++++++++++++++++++- 11 files changed, 57 insertions(+), 3 deletions(-) diff --git a/apps/web/locales/de-DE.json b/apps/web/locales/de-DE.json index dd7f0c1848..bf39f22bab 100644 --- a/apps/web/locales/de-DE.json +++ b/apps/web/locales/de-DE.json @@ -279,6 +279,7 @@ "no_result_found": "Kein Ergebnis gefunden", "no_results": "Keine Ergebnisse", "no_surveys_found": "Keine Umfragen gefunden.", + "none_of_the_above": "Keine der oben genannten Optionen", "not_authenticated": "Du bist nicht authentifiziert, um diese Aktion durchzuführen.", "not_authorized": "Nicht berechtigt", "not_connected": "Nicht verbunden", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Rahmen hinzufügen", "add_highlight_border_description": "Füge deiner Umfragekarte einen äußeren Rahmen hinzu.", "add_logic": "Logik hinzufügen", + "add_none_of_the_above": "Füge \"Keine der oben genannten Optionen\" hinzu", "add_option": "Option hinzufügen", "add_other": "Anderes hinzufügen", "add_photo_or_video": "Foto oder Video hinzufügen", diff --git a/apps/web/locales/en-US.json b/apps/web/locales/en-US.json index bdd443ef65..c4da0adaa6 100644 --- a/apps/web/locales/en-US.json +++ b/apps/web/locales/en-US.json @@ -279,6 +279,7 @@ "no_result_found": "No result found", "no_results": "No results", "no_surveys_found": "No surveys found.", + "none_of_the_above": "None of the above", "not_authenticated": "You are not authenticated to perform this action.", "not_authorized": "Not authorized", "not_connected": "Not Connected", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Add highlight border", "add_highlight_border_description": "Add an outer border to your survey card.", "add_logic": "Add logic", + "add_none_of_the_above": "Add \"None of the Above\"", "add_option": "Add option", "add_other": "Add \"Other\"", "add_photo_or_video": "Add photo or video", diff --git a/apps/web/locales/fr-FR.json b/apps/web/locales/fr-FR.json index e8f5b045e0..bbee4c313b 100644 --- a/apps/web/locales/fr-FR.json +++ b/apps/web/locales/fr-FR.json @@ -279,6 +279,7 @@ "no_result_found": "Aucun résultat trouvé", "no_results": "Aucun résultat", "no_surveys_found": "Aucun sondage trouvé.", + "none_of_the_above": "Aucun des éléments ci-dessus", "not_authenticated": "Vous n'êtes pas authentifié pour effectuer cette action.", "not_authorized": "Non autorisé", "not_connected": "Non connecté", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Ajouter une bordure de surlignage", "add_highlight_border_description": "Ajoutez une bordure extérieure à votre carte d'enquête.", "add_logic": "Ajouter de la logique", + "add_none_of_the_above": "Ajouter \"Aucun des éléments ci-dessus\"", "add_option": "Ajouter une option", "add_other": "Ajouter \"Autre", "add_photo_or_video": "Ajouter une photo ou une vidéo", diff --git a/apps/web/locales/ja-JP.json b/apps/web/locales/ja-JP.json index ab61fb2ef8..6de7841c4d 100644 --- a/apps/web/locales/ja-JP.json +++ b/apps/web/locales/ja-JP.json @@ -279,6 +279,7 @@ "no_result_found": "結果が見つかりません", "no_results": "結果なし", "no_surveys_found": "フォームが見つかりません。", + "none_of_the_above": "いずれも該当しません", "not_authenticated": "このアクションを実行するための認証がされていません。", "not_authorized": "権限がありません", "not_connected": "未接続", @@ -1209,6 +1210,7 @@ "add_highlight_border": "ハイライトボーダーを追加", "add_highlight_border_description": "フォームカードに外側のボーダーを追加します。", "add_logic": "ロジックを追加", + "add_none_of_the_above": "\"いずれも該当しません\" を追加", "add_option": "オプションを追加", "add_other": "「その他」を追加", "add_photo_or_video": "写真または動画を追加", diff --git a/apps/web/locales/pt-BR.json b/apps/web/locales/pt-BR.json index 00cc4facea..4fe20187d1 100644 --- a/apps/web/locales/pt-BR.json +++ b/apps/web/locales/pt-BR.json @@ -279,6 +279,7 @@ "no_result_found": "Nenhum resultado encontrado", "no_results": "Nenhum resultado", "no_surveys_found": "Não foram encontradas pesquisas.", + "none_of_the_above": "Nenhuma das opções acima", "not_authenticated": "Você não está autenticado para realizar essa ação.", "not_authorized": "Não autorizado", "not_connected": "Desconectado", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Adicionar borda de destaque", "add_highlight_border_description": "Adicione uma borda externa ao seu cartão de pesquisa.", "add_logic": "Adicionar lógica", + "add_none_of_the_above": "Adicionar \"Nenhuma das opções acima\"", "add_option": "Adicionar opção", "add_other": "Adicionar \"Outro", "add_photo_or_video": "Adicionar foto ou video", diff --git a/apps/web/locales/pt-PT.json b/apps/web/locales/pt-PT.json index db78e52c47..770d8b4019 100644 --- a/apps/web/locales/pt-PT.json +++ b/apps/web/locales/pt-PT.json @@ -279,6 +279,7 @@ "no_result_found": "Nenhum resultado encontrado", "no_results": "Nenhum resultado", "no_surveys_found": "Nenhum inquérito encontrado.", + "none_of_the_above": "Nenhuma das opções acima", "not_authenticated": "Não está autenticado para realizar esta ação.", "not_authorized": "Não autorizado", "not_connected": "Não Conectado", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Adicionar borda de destaque", "add_highlight_border_description": "Adicione uma borda externa ao seu cartão de inquérito.", "add_logic": "Adicionar lógica", + "add_none_of_the_above": "Adicionar \"Nenhuma das Opções Acima\"", "add_option": "Adicionar opção", "add_other": "Adicionar \"Outro\"", "add_photo_or_video": "Adicionar foto ou vídeo", diff --git a/apps/web/locales/ro-RO.json b/apps/web/locales/ro-RO.json index 74cd9b62fa..46e31f31ea 100644 --- a/apps/web/locales/ro-RO.json +++ b/apps/web/locales/ro-RO.json @@ -279,6 +279,7 @@ "no_result_found": "Niciun rezultat găsit", "no_results": "Nicio rezultat", "no_surveys_found": "Nu au fost găsite sondaje.", + "none_of_the_above": "Niciuna dintre cele de mai sus", "not_authenticated": "Nu sunteți autentificat pentru a efectua această acțiune.", "not_authorized": "Neautorizat", "not_connected": "Neconectat", @@ -1209,6 +1210,7 @@ "add_highlight_border": "Adaugă bordură evidențiată", "add_highlight_border_description": "Adaugă o margine exterioară cardului tău de sondaj.", "add_logic": "Adaugă logică", + "add_none_of_the_above": "Adăugați \"Niciuna dintre cele de mai sus\"", "add_option": "Adăugați opțiune", "add_other": "Adăugați \"Altele\"", "add_photo_or_video": "Adaugă fotografie sau video", diff --git a/apps/web/locales/zh-Hans-CN.json b/apps/web/locales/zh-Hans-CN.json index 3990b1dd8e..455c902b87 100644 --- a/apps/web/locales/zh-Hans-CN.json +++ b/apps/web/locales/zh-Hans-CN.json @@ -279,6 +279,7 @@ "no_result_found": "没有 结果", "no_results": "没有 结果", "no_surveys_found": "未找到 调查", + "none_of_the_above": "以上 都 不 是", "not_authenticated": "您 未 认证 以 执行 该 操作。", "not_authorized": "未授权", "not_connected": "未连接", @@ -1209,6 +1210,7 @@ "add_highlight_border": "添加 高亮 边框", "add_highlight_border_description": "在 你的 调查 卡片 添加 外 边框。", "add_logic": "添加逻辑", + "add_none_of_the_above": "添加 “以上 都 不 是”", "add_option": "添加 选项", "add_other": "添加 \"其他\"", "add_photo_or_video": "添加 照片 或 视频", diff --git a/apps/web/locales/zh-Hant-TW.json b/apps/web/locales/zh-Hant-TW.json index 2fa24a0c54..9db2ba3cd1 100644 --- a/apps/web/locales/zh-Hant-TW.json +++ b/apps/web/locales/zh-Hant-TW.json @@ -279,6 +279,7 @@ "no_result_found": "找不到結果", "no_results": "沒有結果", "no_surveys_found": "找不到問卷。", + "none_of_the_above": "以上皆非", "not_authenticated": "您未經授權執行此操作。", "not_authorized": "未授權", "not_connected": "未連線", @@ -1209,6 +1210,7 @@ "add_highlight_border": "新增醒目提示邊框", "add_highlight_border_description": "在您的問卷卡片新增外邊框。", "add_logic": "新增邏輯", + "add_none_of_the_above": "新增 \"以上皆非\"", "add_option": "新增選項", "add_other": "新增「其他」", "add_photo_or_video": "新增照片或影片", diff --git a/docs/self-hosting/advanced/migration.mdx b/docs/self-hosting/advanced/migration.mdx index 6e2190ae7b..7dd27763d1 100644 --- a/docs/self-hosting/advanced/migration.mdx +++ b/docs/self-hosting/advanced/migration.mdx @@ -143,7 +143,7 @@ No manual intervention is required for the database migration. **4. Verify Your Upgrade** - Access your Formbricks instance at the same URL as before -- Test file uploads to ensure S3/MinIO integration works correctly +- Test file uploads to ensure S3/MinIO integration works correctly. Check the [File Upload Troubleshooting](/self-hosting/configuration/file-uploads#troubleshooting) section if you face any issues. - Verify that existing surveys and data are intact - Check that previously uploaded files are accessible diff --git a/docs/self-hosting/configuration/file-uploads.mdx b/docs/self-hosting/configuration/file-uploads.mdx index ec7216a05f..5686a0edec 100644 --- a/docs/self-hosting/configuration/file-uploads.mdx +++ b/docs/self-hosting/configuration/file-uploads.mdx @@ -230,9 +230,38 @@ services: ## Security Considerations -### S3 Bucket Permissions +### IAM User Permissions -Configure your S3 bucket with a least-privileged policy: +When using AWS S3 or S3-compatible storage providers, ensure that the IAM user associated with your `S3_ACCESS_KEY` and `S3_SECRET_KEY` credentials has the necessary permissions to interact with your bucket. Without proper permissions, file uploads and retrievals will fail. + +The following IAM policy grants the minimum required permissions for Formbricks to function correctly. This policy is also used in the bundled MinIO integration: + +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["s3:DeleteObject", "s3:GetObject", "s3:PutObject"], + "Resource": ["arn:aws:s3:::your-bucket-name/*"] + }, + { + "Effect": "Allow", + "Action": ["s3:ListBucket"], + "Resource": ["arn:aws:s3:::your-bucket-name"] + } + ] +} +``` + + + Replace `your-bucket-name` with your actual S3 bucket name. The first statement grants object-level + operations (upload, retrieve, and delete files), while the second statement allows listing bucket contents. + + +### S3 Bucket Policy + +In addition to IAM user permissions, configure your S3 bucket with a least-privileged bucket policy to ensure security: 1. **Scoped Public Read Access**: Only allow public read access to specific prefixes where needed 2. **Restricted Write Access**: Only your Formbricks instance should be able to upload files @@ -264,6 +293,10 @@ Example least-privileged S3 bucket policy: } ``` + + Replace `your-bucket-name` with your actual bucket name and `arn:aws:iam::123456789012:user/formbricks-service` with the ARN of your IAM user. This policy allows public read access only to specific paths while restricting write access to your Formbricks service user. + + ### MinIO Security When using bundled MinIO: @@ -284,6 +317,9 @@ When using bundled MinIO: 2. Verify bucket exists and is accessible 3. Ensure bucket permissions allow uploads from your server 4. Check network connectivity to S3 endpoint +5. We use S3 presigned URLs for uploads. Make sure your CORS policy allows presigned URL uploads; otherwise, uploads will fail. +Some providers (e.g., Hetzner’s object storage) [require a specific CORS configuration](https://github.com/formbricks/formbricks/discussions/6641#discussioncomment-14574048). +If you’re using the bundled MinIO setup, this is already configured for you. **Images not displaying in surveys:**