Artifactspublic-v0

curl

master
ply4 git calls52 ms288 KiB3 cachedprotocol v2
50 lines1.8 KiBRaw

--resolve

Provide a custom address for a specific host and port pair. Using this, you can make the curl requests(s) use a specified address and prevent the otherwise normally resolved address to be used. Consider it a sort of /etc/hosts alternative provided on the command line. The port number should be the number used for the specific protocol the host is used for. It means you need several entries if you want to provide addresses for the same host but different ports.

By specifying * as host you can tell curl to resolve any host and specific port pair to the specified address. Wildcard is resolved last so any --resolve with a specific host and port is used first.

The provided address set by this option is used even if --ipv4 or --ipv6 is set to make curl use another IP version.

By prefixing the host with a '+' you can make the entry time out after curl's default timeout (1 minute). Note that this only makes sense for long running parallel transfers with a lot of files. In such cases, if this option is used curl tries to resolve the host as it normally would once the timeout has expired.

Provide IPv6 addresses within [brackets].

To redirect connects from a specific hostname or any hostname, independently of port number, consider the --connect-to option.

Support for resolving with wildcard was added in 7.64.0.

Support for the '+' prefix was added in 7.75.0.

Support for specifying the host component as an IPv6 address was added in 8.13.0.

1---
2c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
3SPDX-License-Identifier: curl
4Long: resolve
5Arg: <[+]host:port:addr[,addr]...>
6Help: Resolve host+port to address
7Added: 7.21.3
8Category: connection dns
9Multi: append
10See-also:
11 - connect-to
12 - alt-svc
13Example:
14 - --resolve example.com:443:127.0.0.1 $URL
15 - --resolve example.com:443:[2001:db8::252f:efd6] $URL
16---
18# `--resolve`
20Provide a custom address for a specific host and port pair. Using this, you
21can make the curl requests(s) use a specified address and prevent the
22otherwise normally resolved address to be used. Consider it a sort of
23/etc/hosts alternative provided on the command line. The port number should be
24the number used for the specific protocol the host is used for. It means you
25need several entries if you want to provide addresses for the same host but
26different ports.
28By specifying `*` as host you can tell curl to resolve any host and specific
29port pair to the specified address. Wildcard is resolved last so any --resolve
30with a specific host and port is used first.
32The provided address set by this option is used even if --ipv4 or --ipv6 is
33set to make curl use another IP version.
35By prefixing the host with a '+' you can make the entry time out after curl's
36default timeout (1 minute). Note that this only makes sense for long running
37parallel transfers with a lot of files. In such cases, if this option is used
38curl tries to resolve the host as it normally would once the timeout has
39expired.
41Provide IPv6 addresses within [brackets].
43To redirect connects from a specific hostname or any hostname, independently
44of port number, consider the --connect-to option.
46Support for resolving with wildcard was added in 7.64.0.
48Support for the '+' prefix was added in 7.75.0.
50Support for specifying the host component as an IPv6 address was added in 8.13.0.
Diagnostics4 git calls · 52 ms
CallStatusSizeTime052 ms
discover200152 B3 ms
git.upload-pack discover
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=3
git.response.bytes=152
git.server.agent=gitty/1.0
git.server.object_format=sha1
git.server.caps=agent ls-refs fetch object-format
git.server.fetch=shallow filter sideband-all
git.protocol.version=2
git.pkt.frames=8
git.pkt.data=6
git.pkt.flush=2
git.pkt.delim=0
git.pkt.bytes=152
git.pkt.payload.max=34
ls-refs200149 B · hit3 ms
git.upload-pack ls-refs
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=3
git.response.bytes=149
git.response.cache=HIT
git.response.duration_ms=3
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=149
git.pkt.payload.max=78
git.ls_refs.count=2
git.ls_refs.head=refs/heads/master
fetchblob:none · deepen 10200287 KiB · hit9 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=9
git.response.bytes=293470
git.response.cache=HIT
git.response.duration_ms=9
git.fetch.filter=blob:none
git.fetch.filter.requested=tree:0
git.fetch.filter.fallback=blob:none
git.fetch.filter.learned=false
git.fetch.wants=31c911efe5652725e930f4d2e60c9060e5f6646d
git.fetch.haves.count=0
git.fetch.deepen=10
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=10
git.pkt.data=8
git.pkt.flush=1
git.pkt.delim=1
git.pkt.bytes=293470
git.pkt.payload.max=65516
git.sideband.band1.bytes=293354
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0
git.pack.objects=87
git.pack.bytes=293354
git.pack.ofs_delta=0
git.pack.ref_delta=1
git.pack.chain.max=1
git.pack.trailer=6a646bcda6740bab42e321b51998b52ea15146c0
git.pack.full=86
Open pack map
fetch200999 B · hit40 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=40
git.response.bytes=999
git.response.cache=HIT
git.response.duration_ms=40
git.fetch.wants=18733df0c2bf4f8801ccf3fc6887bb3d1e87e383
git.fetch.haves.count=0
git.fetch.deepen=0
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=999
git.pkt.payload.max=978
git.sideband.band1.bytes=977
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0

Each row is one HTTP round trip ply made to the git server for this page, on one timeline. discover asks what the server speaks, ls-refs lists branch tips, fetch brings objects by id. A hit was served by Workers Cache. Tap a row for its wire details.

Remote
https://5ad2236b39de4c8bd8f6270ea63f3ea9.artifacts.cloudflare.net/git/public-v0/curl.git
Ref
refs/heads/master
Commit
31c911efe5652725e930f4d2e60c9060e5f6646d
cf-ray
a5e2f4347f0c7089
Request
91975415…
Protocol
v2 · sha1
Agent
gitty/1.0
Filter
advertised
Fetch
shallow filter sideband-all
Capabilities
agent ls-refs fetch object-format