Commit a9afe82
committed
Inject content into Docker via volumes, not bind mounts
This is useful, because a) bind mounts are slow and problematic (they
come with various warnings) on Docker Desktop on Windows & Mac) and b)
this moves us slowly towards a world where we can successfully intercept
a _remote_ Docker host (though we still can't yet, mostly because we
don't know the right proxy address to use for HTTP Toolkit).
Note that unlike other Docker services, we ensure the Docker volume is
running synchronously on-demand, not just async when we see Docker
proxy activity.
Without that, if the volume didn't exist for some reason (shouldn't
happen, but possible given races etc or deletion elsewhere) then
containers could've been created referencing it when it didn't exist,
whereupon Docker would create it automatically and break everything.1 parent d45f04c commit a9afe82
File tree
8 files changed
+257
-96
lines changed- src
- interceptors/docker
8 files changed
+257
-96
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
| 18 | + | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
26 | | - | |
27 | 25 | | |
28 | 26 | | |
29 | 27 | | |
| |||
119 | 117 | | |
120 | 118 | | |
121 | 119 | | |
122 | | - | |
| 120 | + | |
123 | 121 | | |
124 | 122 | | |
125 | 123 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | 8 | | |
10 | 9 | | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
| 10 | + | |
15 | 11 | | |
16 | 12 | | |
| 13 | + | |
17 | 14 | | |
18 | 15 | | |
19 | 16 | | |
| |||
74 | 71 | | |
75 | 72 | | |
76 | 73 | | |
77 | | - | |
| 74 | + | |
78 | 75 | | |
79 | 76 | | |
80 | 77 | | |
| |||
91 | 88 | | |
92 | 89 | | |
93 | 90 | | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | 91 | | |
117 | 92 | | |
118 | 93 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | 4 | | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
| 5 | + | |
10 | 6 | | |
| 7 | + | |
11 | 8 | | |
12 | 9 | | |
13 | 10 | | |
| |||
76 | 73 | | |
77 | 74 | | |
78 | 75 | | |
79 | | - | |
| 76 | + | |
80 | 77 | | |
81 | 78 | | |
82 | | - | |
| 79 | + | |
83 | 80 | | |
84 | | - | |
85 | | - | |
| 81 | + | |
86 | 82 | | |
87 | | - | |
| 83 | + | |
88 | 84 | | |
89 | 85 | | |
90 | 86 | | |
| |||
127 | 123 | | |
128 | 124 | | |
129 | 125 | | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
134 | 129 | | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
140 | 133 | | |
141 | 134 | | |
142 | 135 | | |
| |||
195 | 188 | | |
196 | 189 | | |
197 | 190 | | |
198 | | - | |
| 191 | + | |
199 | 192 | | |
200 | 193 | | |
201 | | - | |
202 | 194 | | |
203 | 195 | | |
204 | 196 | | |
| |||
222 | 214 | | |
223 | 215 | | |
224 | 216 | | |
225 | | - | |
226 | | - | |
227 | 217 | | |
228 | 218 | | |
229 | | - | |
| 219 | + | |
230 | 220 | | |
231 | 221 | | |
232 | 222 | | |
233 | 223 | | |
234 | 224 | | |
235 | 225 | | |
236 | | - | |
237 | | - | |
238 | | - | |
239 | | - | |
240 | | - | |
| 226 | + | |
241 | 227 | | |
242 | 228 | | |
243 | 229 | | |
| |||
0 commit comments