Commit 664ace3
committed
Allow VSOCK in Ansible hostnames
The VSOCK address family facilitates communication between virtual
machines and the host they are running on. An example:
https://wiki.archlinux.org/title/QEMU#Accessing_SSH_via_vsock
The separator between the "vsock" identifier and the CID can either be a
forward slash (`/`) or a percent sign (`%`). `urllib.parse.urlparse`
will mistake the forward slash for the beginning of the URL path, but a
percent sign is accepted.
```
>>> urlparse("ansible://vsock/555")
ParseResult(scheme='ansible', netloc='vsock', path='/555', params='', query='', fragment='')
>>> urlparse("ansible://vsock%555")
ParseResult(scheme='ansible', netloc='vsock%555', path='', params='', query='', fragment='')
```1 parent c17794e commit 664ace3
2 files changed
+9
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
212 | 212 | | |
213 | 213 | | |
214 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
215 | 222 | | |
216 | 223 | | |
217 | 224 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
| |||
214 | 215 | | |
215 | 216 | | |
216 | 217 | | |
217 | | - | |
| 218 | + | |
218 | 219 | | |
219 | 220 | | |
220 | 221 | | |
| |||
0 commit comments