Background : The project needs to select a different test platforms, the best platform for a screening
Status : A machine installation sets the environment, a virtual machine too cumbersome
Solution : mounting measured by simulated environment Docker
Reference : https: //blog.csdn.net/qq_32447301/article/details/81394024
Use Docker Yapi Construction
1. Create a data volume MongoDB
Docker mongo_data_yapi Create Volume
2. Start MongoDB
Docker --name Mongo-RUN -d -v mongo_data_yapi Yapi: / Data / DB Mongo
3. Yapi image acquisition, the version information may be mirrored aliyun warehouse View:
address: https://dev.aliyun.com/detail.html?spm=5176.1972343.2.26.I97LV8&repoId=139034
Docker pull registry.cn-hangzhou.aliyuncs.com/anoy/yapi
4. initialize the database indexes and Yapi administrator account
Docker RUN -it --rm --link mongo-Yapi: mongo --entrypoint npm --workdir / API / vendors install registry.cn-hangzhou.aliyuncs.com/anoy/yapi RUN-Server
5. start Yapi services
docker run -d --name yapi --link mongo- yapi: mongo --workdir / api / vendors -p 3000: 3000 registry.cn-hangzhou.aliyuncs.com/anoy/yapi server / app.js
6. Use Yapi
visit http: // localhost: 3000 login account [email protected], password ymfe.org
Status : A machine installation sets the environment, a virtual machine too cumbersome
Solution : mounting measured by simulated environment Docker
Reference : https: //blog.csdn.net/qq_32447301/article/details/81394024
Use Docker Yapi Construction
1. Create a data volume MongoDB
Docker mongo_data_yapi Create Volume
2. Start MongoDB
Docker --name Mongo-RUN -d -v mongo_data_yapi Yapi: / Data / DB Mongo
3. Yapi image acquisition, the version information may be mirrored aliyun warehouse View:
address: https://dev.aliyun.com/detail.html?spm=5176.1972343.2.26.I97LV8&repoId=139034
Docker pull registry.cn-hangzhou.aliyuncs.com/anoy/yapi
4. initialize the database indexes and Yapi administrator account
Docker RUN -it --rm --link mongo-Yapi: mongo --entrypoint npm --workdir / API / vendors install registry.cn-hangzhou.aliyuncs.com/anoy/yapi RUN-Server
5. start Yapi services
docker run -d --name yapi --link mongo- yapi: mongo --workdir / api / vendors -p 3000: 3000 registry.cn-hangzhou.aliyuncs.com/anoy/yapi server / app.js
6. Use Yapi
visit http: // localhost: 3000 login account [email protected], password ymfe.org