前置准备Drone
===
pull image
`docker pull drone/drone`
### 启动Drone server
~~~
docker run -d \
-e DRONE_GOGS=true \
-e DRONE_GOGS_URL=http://192.168.0.100:3000 \
-e DRONE_OPEN=true \
-e DRONE_SECRET=hello1234 \
-v /tmp/drone:/var/lib/drone \
-p 9090:8000 \
--restart=always \
--name=drone \
drone/drone
~~~
命令讲解:DRONE_HOST 配置本机ip
DRONE_GOGS gogs模式
DRONE_GOGS_URL gogs地址
### 启动Drone agent
~~~
docker run -d \
-e DRONE_SERVER=ws://192.168.0.100:9090/ws/broker \
-e DRONE_SECRET=hello1234 \
-v /var/run/docker.sock:/var/run/docker.sock \
--name=drone-agent \
drone/drone agent
~~~