Last active
March 27, 2025 06:40
-
-
Save WoHal/7cb9425f7dfd5b7a33c7a2bfa6a74201 to your computer and use it in GitHub Desktop.
yapi docker_compose file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| services: | |
| yapi: | |
| image: wohal/yapi:latest | |
| container_name: yapi | |
| environment: | |
| - VERSION=1.12.0 | |
| - HOME=/home | |
| - PORT=3000 | |
| - [email protected] # CHANGE ME | |
| - DB_SERVER=mongo | |
| - DB_NAME=yapi | |
| - DB_PORT=27017 | |
| restart: always | |
| ports: | |
| - 3000:3000 | |
| volumes: | |
| - ./log:/home/log # log dir | |
| - ./vendors:/home/vendors | |
| depends_on: | |
| mongo: | |
| condition: service_healthy | |
| mongo: | |
| image: mongo | |
| container_name: mongo | |
| restart: always | |
| healthcheck: | |
| test: echo 'db.runCommand("ping").ok' | mongosh mongo:27017/test --quiet | |
| interval: 10s | |
| timeout: 10s | |
| retries: 5 | |
| start_period: 40s | |
| ports: | |
| - 27017:27017 | |
| volumes: | |
| - ./mongodb:/data/db #db dir |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment