Skip to content
This repository has been archived by the owner on Dec 20, 2024. It is now read-only.

Update docs and example image version #1398

Merged
merged 1 commit into from
Jun 30, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -305,10 +305,13 @@ supernode cdn file server port | supernode --download-port | You should prepare

## Why the time in the log is wrong

If you are in China,docker container uses UTC time(Coordinated Universal Time) and the host uses CST time(China Shanghai Time).So the log's time is 8 hours behind the host time.If you want to make their time consistent,you should add a config `-v /etc/localtime:/etc/localtime:ro` before you start a container.For example,you can run a command as follows to start a dfclient.
If you are in China, docker container uses UTC time(Coordinated Universal Time), and the host uses CST time(China Shanghai Time). So the log's time is 8 hours behind the host time. If you want to make their time consistent, you should add a config `-v /etc/localtime:/etc/localtime:ro` before you start a container. For example, you can run a command as follows to start a dfclient.

```sh
docker run -d --name dfclient -v /etc/localtime:/etc/localtime:ro -p 65001:65001 dragonflyoss/dfclient:0.4.0 --registry https://index.docker.io
docker run -d --name dfclient \
-v /etc/localtime:/etc/localtime:ro \
-p 65001:65001 \
dragonflyoss/dfclient:1.0.2 --registry https://index.docker.io
```

## How to join Dragonfly as a member
Expand Down
13 changes: 11 additions & 2 deletions docs/config/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,20 @@ When deploying with Docker, you can mount the default path when starting up imag
For supernode, you should start a supernode image using the following command.

```sh
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
docker run -d --name supernode \
--restart=always \
-p 8001:8001 \
-p 8002:8002 \
-v /etc/dragonfly/supernode.yml:/etc/dragonfly/supernode.yml \
dragonflyoss/supernode:1.0.2
```

For dfdaemon, you can start the image in the same way.

```sh
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
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:1.0.2
```
15 changes: 12 additions & 3 deletions docs/quick_start/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,28 @@ If you are using Dragonfly in your **production environment** to handle producti

## Prerequisites

All steps in this document are done on the same machine using the docker container, so make sure the docker container engine is installed and started on your machine. You can also refer to the documentation: [multi-machine deployment](../user_guide/multi_machines_deployment.md) to experience Dragonfly.
All steps in this document is doing on the same machine using the docker container, so make sure the docker container engine installed and started on your machine. You can also refer to the documentation: [multi-machine deployment](../user_guide/multi_machines_deployment.md) to experience Dragonfly.

## Step 1: Deploy Dragonfly Server (SuperNode)

```bash
docker run -d --name supernode --restart=always -p 8001:8001 -p 8002:8002 -v /home/admin/supernode:/home/admin/supernode dragonflyoss/supernode:0.4.3
docker run -d --name supernode \
--restart=always \
-p 8001:8001 \
-p 8002:8002 \
-v /home/admin/supernode:/home/admin/supernode \
dragonflyoss/supernode:1.0.2
```

## Step 2: Deploy Dragonfly Client (dfclient)

```bash
SUPERNODE_IP=`docker inspect supernode -f '{{.NetworkSettings.Networks.bridge.IPAddress}}'`
docker run -d --name dfclient --restart=always -p 65001:65001 -v $HOME/.small-dragonfly:/root/.small-dragonfly dragonflyoss/dfclient:0.4.3 --registry https://index.docker.io --node $SUPERNODE_IP
docker run -d --name dfclient \
--restart=always \
-p 65001:65001 \
-v $HOME/.small-dragonfly:/root/.small-dragonfly \
dragonflyoss/dfclient:1.0.2 --registry https://index.docker.io --node $SUPERNODE_IP
```

**NOTE**:
Expand Down
13 changes: 10 additions & 3 deletions docs/user_guide/multi_machines_deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,12 @@ Then, we must provide:
Deploy the Dragonfly server (Supernode) on the machine `dfsupernode`.

```bash
docker run -d --name supernode --restart=always -p 8001:8001 -p 8002:8002 -v /home/admin/supernode:/home/admin/supernode dragonflyoss/supernode:0.4.3 --download-port=8001
docker run -d --name supernode \
--restart=always \
-p 8001:8001 \
-p 8002:8002 \
-v /home/admin/supernode:/home/admin/supernode \
dragonflyoss/supernode:1.0.2 --download-port=8001
```

## Step 2: Deploy Dragonfly Client (dfclient)
Expand All @@ -48,10 +53,12 @@ EOD
### Start Dragonfly Client

```bash
docker run -d --name dfclient --restart=always -p 65001:65001 \
docker run -d --name dfclient \
--restart=always \
-p 65001:65001 \
-v /etc/dragonfly:/etc/dragonfly \
-v $HOME/.small-dragonfly:/root/.small-dragonfly \
dragonflyoss/dfclient:0.4.3 --registry https://index.docker.io
dragonflyoss/dfclient:1.0.2 --registry https://index.docker.io
```

**NOTE**: The `--registry` parameter specifies the mirrored image registry address, and `https://index.docker.io` is the address of official image registry, you can also set it to the others.
Expand Down