Skip to content
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

docs: Install a supported webdriver in the Celery worker on Kubernetes deployment #26370

Closed
3 tasks done
dbaltor opened this issue Dec 27, 2023 · 0 comments · Fixed by #26371
Closed
3 tasks done

docs: Install a supported webdriver in the Celery worker on Kubernetes deployment #26370

dbaltor opened this issue Dec 27, 2023 · 0 comments · Fixed by #26371
Labels
infra:container Infra container and K8s

Comments

@dbaltor
Copy link
Contributor

dbaltor commented Dec 27, 2023

The instructions in the Install a supported webdriver in the Celery worker section in running-on-kubernetes.mdx cause the chromedriver installation to fail when configuring superset workers.

How to reproduce the bug

  1. Configure helm values.yaml as per the guide by adding the following snippet:
  supersetWorker:
    # Install chromedriver used to send Alerts and Reports
    command:
      - /bin/sh
      - -c
      - |
        # Install chrome webdriver
        # See https://github.com/apache/superset/blob/4fa3b6c7185629b87c27fc2c0e5435d458f7b73d/docs/src/pages/docs/installation/email_reports.mdx
        apt update
        wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
        apt install -y --no-install-recommends ./google-chrome-stable_current_amd64.deb
        wget https://chromedriver.storage.googleapis.com/88.0.4324.96/chromedriver_linux64.zip
        unzip chromedriver_linux64.zip
        chmod +x chromedriver
        mv chromedriver /usr/bin
        apt autoremove -yqq --purge
        apt clean
        rm -f google-chrome-stable_current_amd64.deb chromedriver_linux64.zip
  
        # Run
        . {{ .Values.configMountPath }}/superset_bootstrap.sh; celery --app=superset.tasks.celery_app:app worker

  1. Deploy Superset on K8s
  2. Check celery worker logs: kubectl logs -f superset-worker-<xxx>
  3. See multiple errors and warnings:
22 packages can be upgraded. Run 'apt list --upgradable' to see them.
/bin/sh: 4: wget: not found

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

Reading package lists...
E: Unsupported file ./google-chrome-stable_current_amd64.deb given on commandline
/bin/sh: 6: wget: not found
/bin/sh: 7: unzip: not found
chmod: cannot access 'chromedriver': No such file or directory
mv: cannot stat 'chromedriver': No such file or directory

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

0 upgraded, 0 newly installed, 0 to remove and 22 not upgraded.

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

Expected results

Clean logs and `chromodriver successfully installed as per below logs:

Archive:  chromedriver_linux64.zip
  inflating: chromedriver  

Actual results

chromedriver installation fails

Environment

(please complete the following information):

  • superset version: 3.0.1

Checklist

Make sure to follow these steps before submitting your issue - thank you!

  • I have checked the superset logs for python stacktraces and included it here as text if there are any.
  • I have reproduced the issue with at least the latest released version of superset.
  • I have checked the issue tracker for the same issue and I haven't found one similar.

Additional context

The errors are being caused by wget and unzip not being present in the container image and the warnings are due to the use of apt rather than apt-get.

@sfirke sfirke added the infra:container Infra container and K8s label Dec 28, 2023
@sfirke sfirke changed the title docs: Install a supported webdriver in the Celery worker docs: Install a supported webdriver in the Celery worker on Kubernetes deploymnt Dec 28, 2023
@sfirke sfirke changed the title docs: Install a supported webdriver in the Celery worker on Kubernetes deploymnt docs: Install a supported webdriver in the Celery worker on Kubernetes deployment Dec 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infra:container Infra container and K8s
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants