voidking opened a new issue, #13568: URL: https://github.com/apache/dolphinscheduler/issues/13568
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and found no similar feature requirement. ### Description I have installed delphinscheduler 3.1.2 followed the [Docker 快速使用教程](https://dolphinscheduler.apache.org/zh-cn/docs/3.1.2/guide/start/docker). Now we need a python environment to run some tasks. I have referenced the document [DolphinScheduler扩容/缩容 文档](https://dolphinscheduler.apache.org/zh-cn/docs/3.1.2/guide/expansion-reduction). However, It isn't suitable for delphinscheduler installed by docker-compose. Because the config file `conf/config/install_config.conf` didn't show in the master and worker containers. I tried to add a new worker by docker-compose. 1. Built a image based on `apache/dolphinscheduler-worker:3.1.2`. ```Dockerfile FROM apache/dolphinscheduler-worker:3.1.2 RUN apt update && apt install python2 && apt install python3 RUN ln -s /usr/bin/python2 /usr/bin/python ``` 2. Added specification to docker-compose.yml ```yaml dolphinscheduler-worker2: image: apache/dolphinscheduler-worker:3.1.2-python2.7.18 command: ["/bin/bash", "./bin/start.sh"] profiles: ["all"] env_file: .env healthcheck: test: [ "CMD", "curl", "http://localhost:1235/actuator/health" ] interval: 30s timeout: 5s retries: 3 depends_on: dolphinscheduler-zookeeper: condition: service_healthy volumes: - dolphinscheduler-worker-data:/tmp/dolphinscheduler - dolphinscheduler-logs:/opt/dolphinscheduler/logs - dolphinscheduler-shared-local:/opt/soft - dolphinscheduler-resource-local:/dolphinscheduler - /data/ds/libs/mysql-connector-java-8.0.16.jar:/opt/dolphinscheduler/libs/mysql-connector-java-8.0.16.jar networks: - dolphinscheduler ``` 3. Restarted all the service. ```bash docker-compose --profile all down docker-compose --profile schema down docker-compose --profile schema up -d docker-compose --profile all up -d docker-compose --profile all ps ``` Then docker-dolphinscheduler-master-1 and docker-dolphinscheduler-worker2-1 can not started. ``` NAME COMMAND SERVICE STATUS PORTS docker-dolphinscheduler-alert-1 "/bin/bash ./bin/sta…" dolphinscheduler-alert running (healthy) 50052-50053/tcp docker-dolphinscheduler-api-1 "/bin/bash ./bin/sta…" dolphinscheduler-api running (healthy) 0.0.0.0:12345->12345/tcp, 0.0.0.0:25333->25333/tcp docker-dolphinscheduler-master-1 "/bin/bash ./bin/sta…" dolphinscheduler-master exited (1) docker-dolphinscheduler-postgresql-1 "/opt/bitnami/script…" dolphinscheduler-postgresql running (healthy) 0.0.0.0:5432->5432/tcp docker-dolphinscheduler-worker-1 "/bin/bash ./bin/sta…" dolphinscheduler-worker running (healthy) 1235/tcp docker-dolphinscheduler-worker2-1 "/bin/bash ./bin/sta…" dolphinscheduler-worker2 exited (1) docker-dolphinscheduler-zookeeper-1 "/opt/bitnami/script…" dolphinscheduler-zookeeper running (healthy) 2181/tcp, 2888/tcp, 3888/tcp, 8080/tcp ``` The log of docker-dolphinscheduler-master-1 shows like follow: ``` Caused by: org.apache.dolphinscheduler.registry.api.RegistryException: zookeeper connect timeout: dolphinscheduler-zookeeper:2181 at org.apache.dolphinscheduler.plugin.registry.zookeeper.ZookeeperRegistry.start(ZookeeperRegistry.java:110) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:389) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:333) at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:157) ... 88 more ``` So, what is the right method to add a python worker for DS installed by docker-compose? ### Documentation Links _No response_ ### Are you willing to submit a PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
