[root@node1 server]# docker-compose -f flink.yml up -d
/usr/local/lib/python3.6/site-packages/paramiko/transport.py:32: CryptographyDeprecationWarning: Python 3.6 is no longer supported by the Python core team. Therefore, support for it is deprecated in cryptography. The next release of cryptography will remove support for Python 3.6.
from cryptography.hazmat.backends import default_backend
Creating network "server_flink_network" with driver "bridge"
WARNING: Found orphan containers (kafka2, kafka1, kafka3) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up.
WARNING: The "taskmanager" service specifies a port on the host. If multiple containers for this service are created on a single host, the port will clash.
Creating server_taskmanager_1 ... done
Creating server_taskmanager_2 ... done
Creating server_taskmanager_3 ... done
[root@node1 server]# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
e908f25d0df5 flink:latest "/docker-entrypoint.…" 6 seconds ago Up 2 seconds 6123/tcp, 0.0.0.0:8084->8081/tcp, :::8084->8081/tcp server_taskmanager_1
8ebe74a4481a flink:latest "/docker-entrypoint.…" 6 seconds ago Up 2 seconds 6123/tcp, 0.0.0.0:8083->8081/tcp, :::8083->8081/tcp server_taskmanager_2
11936734f5cf flink:latest "/docker-entrypoint.…" 6 seconds ago Up 3 seconds 6123/tcp, 0.0.0.0:8082->8081/tcp, :::8082->8081/tcp server_taskmanager_3
e053c7560ee9 flink:latest "/docker-entrypoint.…" 8 seconds ago Up 6 seconds 6123/tcp, 0.0.0.0:8081->8081/tcp, :::8081->8081/tcp jobmanager
[root@node1 server]#
复制代码
乐成后在网页上面输入node1:8081进入这个网站(偶然间由于网络不好会进入不了这个网站)
然后就ok了!
(3)关闭flink集群代码
docker-compose -f flink.yml down
复制代码
效果如下
[root@node1 server]# docker-compose -f flink.yml down
/usr/local/lib/python3.6/site-packages/paramiko/transport.py:32: CryptographyDeprecationWarning: Python 3.6 is no longer supported by the Python core team. Therefore, support for it is deprecated in cryptography. The next release of cryptography will remove support for Python 3.6.
from cryptography.hazmat.backends import default_backend
Stopping server_taskmanager_1 ... done
Stopping server_taskmanager_2 ... done
Stopping server_taskmanager_3 ... done
Stopping jobmanager ... done
WARNING: Found orphan containers (kafka2, kafka3, kafka1) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up.