You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "Vitor-Avila (via GitHub)" <gi...@apache.org> on 2025/10/29 20:05:43 UTC

[PR] chore: Docs and config improvements for Docker setup [superset]

Vitor-Avila opened a new pull request, #35896:
URL: https://github.com/apache/superset/pull/35896

   ### SUMMARY
   Adding more docs on how to customize/extend Docker settings, and also adding more config files to `.gitignore`.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   N/A
   
   ### TESTING INSTRUCTIONS
   Run `docker compose build` and `docker compose up -d` and confirm things still work proeprly. 
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #35896:
URL: https://github.com/apache/superset/pull/35896#issuecomment-3463679782

   AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "sfirke (via GitHub)" <gi...@apache.org>.
sfirke commented on PR #35896:
URL: https://github.com/apache/superset/pull/35896#issuecomment-3468667523

   Looks like you are adding Pillow to the base Docker image. I'm fine with that, and once this PR is in a major release I'll update https://superset.apache.org/docs/installation/docker-builds/ to remove Pillow as an add-on.
   
   But are Playwright and Chrome still not installed in the `python-common` or `lean` layers by default? If that's still the case, then does it help to add Pillow here? I think of Pillow as being needed for Alerts & Reports but if someone has to install Playwright and Chrome anyway would they install it then? Just wondering, and maybe I'm off-base here.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "Vitor-Avila (via GitHub)" <gi...@apache.org>.
Vitor-Avila merged PR #35896:
URL: https://github.com/apache/superset/pull/35896


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "Vitor-Avila (via GitHub)" <gi...@apache.org>.
Vitor-Avila commented on PR #35896:
URL: https://github.com/apache/superset/pull/35896#issuecomment-3471376260

   > Looks like you are adding Pillow to the base Docker image. I'm fine with that, and once this PR is in a major release I'll update https://superset.apache.org/docs/installation/docker-builds/ to remove Pillow as an add-on.
   > 
   > But are Playwright and Chrome still not installed in the `python-common` or `lean` layers by default? If that's still the case, then does it help to add Pillow here? I think of Pillow as being needed for Alerts & Reports but if someone has to install Playwright and Chrome anyway would they install it then? Just wondering, and maybe I'm off-base here.
   
   Oh, you're right. I actually included it there just because in [this example](https://superset.apache.org/docs/installation/docker-builds/#building-your-own-production-docker-image) we have:
   ```
   ...
   RUN . /app/.venv/bin/activate && \
       uv pip install \
       # install psycopg2 for using PostgreSQL metadata store - could be a MySQL package if using that backend:
       psycopg2-binary \
       # add the driver(s) for your data warehouse(s), in this example we're showing for Microsoft SQL Server:
       pymssql \
       # package needed for using single-sign on authentication:
       Authlib \
       # openpyxl to be able to upload Excel files
       openpyxl \
       # Pillow for Alerts & Reports to generate PDFs of dashboards
       Pillow \
       # install Playwright for taking screenshots for Alerts & Reports. This assumes the feature flag PLAYWRIGHT_REPORTS_AND_THUMBNAILS is enabled
       # That feature flag will default to True starting in 6.0.0
       # Playwright works only with Chrome.
       # If you are still using Selenium instead of Playwright, you would instead install here the selenium package and a headless browser & webdriver
       playwright \
       && playwright install-deps \
       && PLAYWRIGHT_BROWSERS_PATH=/usr/local/share/playwright-browsers playwright install chromium
   
   ...
   ```
   
   I saw there _"Pillow for Alerts & Reports to generate PDFs of dashboards"_ and thought it was also needed for PDF reports which we want to use Playwright as well.
   
   Let me remove that part -- thanks for catching it!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #35896:
URL: https://github.com/apache/superset/pull/35896#issuecomment-3463705360

   <details open>
     <summary><strong>Interaction Diagram by <a href="https://bito.ai#sequence_diagram">Bito</a></strong></summary>
   
   ```mermaid
   sequenceDiagram
   participant Dev as Developer
   participant DockerBuild as Docker Build Pipeline<br/>🔄 Updated | ●●○ Medium
   participant Playwright as Playwright Module<br/>🔄 Updated | ●●○ Medium
   participant Pillow as Pillow Dependency<br/>🔄 Updated | ●●○ Medium
   participant WSConfig as WebSocket Config<br/>🔄 Updated | ●●○ Medium
   participant WSService as WebSocket Service
   participant Redis as Redis Cache
   Dev->>DockerBuild: Build with INCLUDE_CHROMIUM/FIREFOX flags
   DockerBuild->>Playwright: Set PLAYWRIGHT_BROWSERS_PATH env
   Playwright->>Pillow: Install playwright + Pillow together
   DockerBuild->>WSConfig: Mount config.example.json (read-only)
   WSConfig->>WSService: Load WebSocket configuration
   WSService->>Redis: Connect to Redis for async events
   Redis-->>WSService: Return connection status
   Note over Dev, WSConfig: Config overrides via .env-local and custom config.json (git-ignored)
   ```
   Critical path: Developer-&gt;Docker Build Pipeline-&gt;Playwright Module-&gt;Pillow Dependency-&gt;WebSocket Config-&gt;WebSocket Service-&gt;Redis Cache
   
   
   > **Note:** Docker build now sets PLAYWRIGHT_BROWSERS_PATH and installs Pillow alongside Playwright for browser automation. WebSocket service config changed to use read-only example mount with optional custom config.json override pattern. Configuration documentation updated to support environment variable and WebSocket config overrides.
   
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore: Docs and config improvements for Docker setup [superset]

Posted by "Vitor-Avila (via GitHub)" <gi...@apache.org>.
Vitor-Avila commented on PR #35896:
URL: https://github.com/apache/superset/pull/35896#issuecomment-3471397528

   > But are Playwright and Chrome still not installed in the `python-common` or `lean` layers by default? If that's still the case, then does it help to add Pillow here? I think of Pillow as being needed for Alerts & Reports but if someone has to install Playwright and Chrome anyway would they install it then? Just wondering, and maybe I'm off-base here.
   
   I had trouble getting Playwright to work out of the box with `docker compose`. Adding `INCLUDE_CHROMIUM=true` in the `.env-local` was not sufficient, I had to include it in the command (`INCLUDE_CHROMIUM=true docker compose`), so tackled that using a `docker-compose.override.yml` file.
   
   As for the use-cases, you're correct. It's possible the user is only focusing on Alerts & Reports (which can use Playwright) or on the other hand just looking to have async PDF download in dashboards.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org