dragonflyoss / Dragonfly2

Dragonfly is an open source P2P-based file distribution and image acceleration system. It is hosted by the Cloud Native Computing Foundation (CNCF) as an Incubating Level Project.
https://d7y.io
Apache License 2.0
2.1k stars 264 forks source link

How to reuse the same dfdaemon in a k8s cluster #3280

Open lihuawei321 opened 1 month ago

lihuawei321 commented 1 month ago

I deployed dfdaemon in the cluster through a DaemonSet. I want all the pods in this cluster to use dfget to pull files from object storage. How can I reuse dfdaemon? image

gaius-qi commented 1 month ago

You can use dfget daemon to run dfdaemon in node and expose daemon unix socket to pod. Dfget downloads file with --daemon-sock options in Pod.

image

lihuawei321 commented 1 month ago

You can use dfget daemon to run dfdaemon in node and expose daemon unix socket to pod. Dfget downloads file with --daemon-sock options in Pod.

image

image

image

I have deployed a dfdaemon on each node. How should I use the dfget --daemon-sock command in my own pod to utilize the exposed socket?

gaius-qi commented 3 weeks ago

You need to mount Unix socket file to pod.