🤖❣️Docker❣️
Last updated
Last updated
Docker的好处不用过多介绍了吧?好比一键启动!
推荐Ubuntu最新版本
先演示效果
安装Docker 和 docker-compose、portainer_agent
安装docker
curl -sSL https://get.daocloud.io/docker | sh
安装docker-compose
sudo usermod -aG docker $USER
sudo apt install docker-compose
安装portainer_agent
docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent
导入镜像 linux-amd64(其他平台镜像自行构建)
docker load rst.tar
修改docker-compose.yml
version: "3"
services:
app-1:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8081
ports:
- "8081:8081"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8081" "TOKEN" 300 ""
app-2:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8082
ports:
- "8082:8082"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8082" "TOKEN" 300 ""
app-3:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8083
ports:
- "8083:8083"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8083" "TOKEN" 300 ""
app-4:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8084
ports:
- "8084:8084"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8084" "TOKEN" 300 ""
app-5:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8085
ports:
- "8085:8085"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8085" "TOKEN" 300 ""
app-6:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8086
ports:
- "8086:8086"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8086" "TOKEN" 300 ""
app-7:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8087
ports:
- "8087:8087"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8087" "TOKEN" 300 ""
app-8:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8088
ports:
- "8088:8088"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8088" "TOKEN" 300 ""
app-9:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8089
ports:
- "8089:8089"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8089" "TOKEN" 300 ""
app-10:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8090
ports:
- "8090:8090"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8090" "TOKEN" 300 ""
app-11:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8091
ports:
- "8091:8091"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8091" "TOKEN" 300 ""
app-12:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8092
ports:
- "8092:8092"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8092" "TOKEN" 300 ""
app-13:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8093
ports:
- "8093:8093"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8093" "TOKEN" 300 ""
app-14:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8094
ports:
- "8094:8094"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8094" "TOKEN" 300 ""
app-15:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8095
ports:
- "8095:8095"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8095" "TOKEN" 300 ""
app-16:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8096
ports:
- "8096:8096"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8096" "TOKEN" 300 ""
app-17:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8097
ports:
- "8097:8097"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8097" "TOKEN" 300 ""
app-18:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8098
ports:
- "8098:8098"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8098" "TOKEN" 300 ""
app-19:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8099
ports:
- "8099:8099"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8099" "TOKEN" 300 ""
app-20:
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
image: wechattoy:v20220816
container_name: WeChatToy-8100
ports:
- "8100:8100"
volumes:
- /root/apps/UsersConf:/apps/UsersConf
command: ./WeChatToy "0.0.0.0:8100" "TOKEN" 300 ""
可根据机器性能开启不同的实例
创建用户目录
mkdir -pv /root/apps/UsersConf
启动
docker-compose up -d
不想自己搭建的我可以帮你免费搭建 测试用户自己折腾吧