-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
125 lines (114 loc) · 3.29 KB
/
docker-compose.yml
File metadata and controls
125 lines (114 loc) · 3.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
version: '3.8'
services:
# Standard version: For general conversion
converter:
build:
context: .
dockerfile: Dockerfile
image: md2word:latest
volumes:
- ./input:/workspace/input:ro
- ./output:/workspace/output
- ./config:/app/config:ro
environment:
- DOTNET_ENVIRONMENT=Production
# Default command (run with docker-compose up converter)
command: ["input/sample.md", "-o", "output/sample.docx", "--preset", "default"]
# Slim version: Lightweight
slim:
build:
context: .
dockerfile: Dockerfile.slim
image: md2word:slim
volumes:
- ./input:/workspace/input:ro
- ./output:/workspace/output
command: ["input/sample.md", "-o", "output/sample-slim.docx"]
# Full version: Rich fonts
full:
build:
context: .
dockerfile: Dockerfile.full
image: md2word:full
volumes:
- ./input:/workspace/input:ro
- ./output:/workspace/output
command: ["input/sample.md", "-o", "output/sample-full.docx"]
# Business document conversion
business:
build:
context: .
dockerfile: Dockerfile
image: md2word:latest
volumes:
- ./input:/workspace/input:ro
- ./output:/workspace/output
- ./config:/app/config:ro
command: ["input/sample.md", "-o", "output/sample-business.docx", "--preset", "business"]
# Vertical text conversion (Japanese novels)
vertical:
build:
context: .
dockerfile: Dockerfile
image: md2word:latest
volumes:
- ./novel:/workspace/novel:ro
- ./output:/workspace/output
- ./config:/app/config:ro
command: ["novel/chapter1.md", "-o", "output/chapter1.docx", "--preset", "vertical-novel", "--preset-dir", "/app/config/vertical"]
# Technical documentation conversion
technical:
build:
context: .
dockerfile: Dockerfile
image: md2word:latest
volumes:
- ./docs:/workspace/docs:ro
- ./output:/workspace/output
command: ["docs/README.md", "-o", "output/README.docx", "--preset", "technical"]
# Batch conversion (multiple files)
batch:
build:
context: .
dockerfile: Dockerfile
image: md2word:latest
volumes:
- ./input:/workspace/input:ro
- ./output:/workspace/output
command: ["input/*.md", "-o", "output/", "--preset", "default"]
# Development (hot-reload)
dev:
build:
context: .
dockerfile: Dockerfile.dev
image: md2word:dev
volumes:
- ./csharp-version/src:/app/src
- ./config:/app/config
- ./input:/workspace/input
- ./output:/workspace/output
# Keep bin/obj inside container (do not mount)
- /app/src/bin
- /app/src/obj
environment:
- DOTNET_ENVIRONMENT=Development
- DOTNET_WATCH_RESTART_ON_RUDE_EDIT=true
command: ["dotnet", "watch", "--project", "/app/src/MarkdownToDocx.CLI", "run", "--", "input/sample.md", "-o", "output/sample.docx"]
# Test execution
test:
build:
context: .
dockerfile: Dockerfile
image: md2word:test
volumes:
- ./tests:/workspace/tests:ro
- ./output:/workspace/output
command: ["dotnet", "test", "/app/MarkdownToDocx.Tests.dll"]
# Named volumes (for persistence if needed)
volumes:
output_data:
driver: local
# Networks (if needed)
networks:
md2word_network:
driver: bridge