下载地址:mirrors.aliyun.com/docker-tool…python
坑: 不要去官网下载,下载速度极慢git
python3 -m pip install docker-compose
复制代码
下载缓慢的话,设置国内镜像:github
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host=mirrors.aliyun.com
复制代码
根据 yaml
启动docker 容器.docker
以 artipub
为例(github.com/crawlab-tea… ):后端
docker-compose.yaml
,写入:version: '3.3'
services:
app:
image: "tikazyq/artipub:latest"
environment:
MONGO_HOST: "mongo"
ARTIPUB_API_ADDRESS: "http://localhost:3000" # 后端 API 地址,若是安装地址不在本机,请修改成协议 + 服务器 IP 地址 + 端口号(默认为 3000)
ports:
- "8000:8000" # frontend
- "3000:3000" # backend
depends_on:
- mongo
mongo:
image: mongo:latest
restart: always
ports:
- "27017:27017"
复制代码
docker-compose up
这一步也很坑,下载很慢(由于 image
是从国外下载的),有两种解决方式:http://localhost:8000/
便可彻底不用担忧什么环境问题,依赖包的版本兼容问题.浏览器
"registry-mirrors": [
"http://xxxx.mirror.aliyuncs.com",
"http://docker.mirrors.ustc.edu.cn"
]
复制代码
阿里云镜像加速地址设置方式教程:cr.console.aliyun.com/cn-hangzhou…bash
开源的一文多发平台,能够帮助文章做者将编写好的文章自动发布到掘金、SegmentFault、CSDN、知乎、开源中国等技术媒体平台服务器
支持的平台:cookie
实际发布效果:多线程
cookies
导入不稳定个人滴滴云专属AI大师码:3388, 购买滴滴云GPU等AI产品输入大师码享9折优惠。 点击 www.didiyun.com前往滴滴云官网购买
本篇文章由一文多发平台ArtiPub自动发布