Last active
June 1, 2019 12:41
-
-
Save thanch2n/901ce9937f660624eed6209b7e5f591e to your computer and use it in GitHub Desktop.
This file contains 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
version: '3.7' | |
# docker config create v2_conf config_v2.json | |
services: | |
v2: | |
image: v2ray/official:latest | |
ports: | |
- "53428:53428/tcp" | |
- "53428:53428/udp" | |
- "53429:53429/tcp" | |
- "53429:53429/udp" | |
# volumes: | |
# - "./config_v2.json:/etc/v2ray/config.json" | |
configs: | |
- source: v2_conf | |
target: /etc/v2ray/config.json | |
deploy: | |
labels: | |
com.description: "v2ray" | |
mode: replicated | |
replicas: 1 | |
update_config: | |
parallelism: 2 | |
delay: 2s | |
monitor: 0s | |
failure_action: rollback | |
max_failure_ratio: 0.3 | |
order: stop-first | |
restart_policy: | |
condition: on-failure | |
delay: 2s | |
max_attempts: 3 | |
window: 10s | |
resources: | |
limits: | |
cpus: "0.8" | |
memory: 500M | |
configs: | |
v2_conf: | |
external: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment