All the documents in config
folder help user to configure Dragonfly.
We can use cli and yaml file to configure Dragonfly when deploying the system. This tutorial only teaches you how to configure by yaml file. If you want to config Dragonfly by cli, you can read docs in cli_reference folder. In fact, learn this tutorial also will help you a lot, because the two ways are similar.
Because Dragonfly is composed of supernode, dfget, dfdaemon, you should learn how to configure them separately. You can reference the three tutorials(supernode, dfget, dfdaemon) to finish the yaml file and deploy.
When deploying with Docker, you can mount the default path when starting up image with -v
.
For supernode, you should start a supernode image using the following command.
docker run -d --name supernode --restart=always -p 8001:8001 -p 8002:8002 -v /etc/dragonfly/supernode.yml:/etc/dragonfly/supernode.yml dragonflyoss/supernode:0.4.3
For dfdaemon, you can start the image in the same way.
docker run -d --net=host --name dfclient -p 65001:65001 -v /etc/dragonfly/dfdaemon.yml:/etc/dragonfly/dfdaemon.yml -v /root/.small-dragonfly:/root/.small-dragonfly dragonflyoss/dfclient:0.4.3