qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: qemu-block@nongnu.org
Cc: kwolf@redhat.com, pbonzini@redhat.com, qemu-devel@nongnu.org,
	timao@redhat.com
Subject: [PATCH 4/5] docs: Only mention curl in the man page when available
Date: Mon, 31 Jan 2022 18:04:10 +0100	[thread overview]
Message-ID: <20220131170411.125198-5-kwolf@redhat.com> (raw)
In-Reply-To: <20220131170411.125198-1-kwolf@redhat.com>

If curl is disabled in the build, the man page shouldn't contain
information on how to use the curl block drivers.

This patch is best viewed with whitespace changes ignored.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 docs/system/device-url-syntax.rst.inc | 114 +++++++++++++-------------
 1 file changed, 58 insertions(+), 56 deletions(-)

diff --git a/docs/system/device-url-syntax.rst.inc b/docs/system/device-url-syntax.rst.inc
index 84a8145292..d55622847a 100644
--- a/docs/system/device-url-syntax.rst.inc
+++ b/docs/system/device-url-syntax.rst.inc
@@ -128,87 +128,89 @@ special URL syntax.
 
    See also http://www.gluster.org.
 
-``HTTP/HTTPS/FTP/FTPS``
-   QEMU supports read-only access to files accessed over http(s) and
-   ftp(s).
+.. only:: not DISABLE_CURL
 
-   Syntax using a single filename:
+    ``HTTP/HTTPS/FTP/FTPS``
+       QEMU supports read-only access to files accessed over http(s) and
+       ftp(s).
 
-   ::
+       Syntax using a single filename:
 
-      <protocol>://[<username>[:<password>]@]<host>/<path>
+       ::
 
-   where:
+          <protocol>://[<username>[:<password>]@]<host>/<path>
 
-   ``protocol``
-      'http', 'https', 'ftp', or 'ftps'.
+       where:
 
-   ``username``
-      Optional username for authentication to the remote server.
+       ``protocol``
+          'http', 'https', 'ftp', or 'ftps'.
 
-   ``password``
-      Optional password for authentication to the remote server.
+       ``username``
+          Optional username for authentication to the remote server.
 
-   ``host``
-      Address of the remote server.
+       ``password``
+          Optional password for authentication to the remote server.
 
-   ``path``
-      Path on the remote server, including any query string.
+       ``host``
+          Address of the remote server.
 
-   The following options are also supported:
+       ``path``
+          Path on the remote server, including any query string.
 
-   ``url``
-      The full URL when passing options to the driver explicitly.
+       The following options are also supported:
 
-   ``readahead``
-      The amount of data to read ahead with each range request to the
-      remote server. This value may optionally have the suffix 'T', 'G',
-      'M', 'K', 'k' or 'b'. If it does not have a suffix, it will be
-      assumed to be in bytes. The value must be a multiple of 512 bytes.
-      It defaults to 256k.
+       ``url``
+          The full URL when passing options to the driver explicitly.
 
-   ``sslverify``
-      Whether to verify the remote server's certificate when connecting
-      over SSL. It can have the value 'on' or 'off'. It defaults to
-      'on'.
+       ``readahead``
+          The amount of data to read ahead with each range request to the
+          remote server. This value may optionally have the suffix 'T', 'G',
+          'M', 'K', 'k' or 'b'. If it does not have a suffix, it will be
+          assumed to be in bytes. The value must be a multiple of 512 bytes.
+          It defaults to 256k.
 
-   ``cookie``
-      Send this cookie (it can also be a list of cookies separated by
-      ';') with each outgoing request. Only supported when using
-      protocols such as HTTP which support cookies, otherwise ignored.
+       ``sslverify``
+          Whether to verify the remote server's certificate when connecting
+          over SSL. It can have the value 'on' or 'off'. It defaults to
+          'on'.
 
-   ``timeout``
-      Set the timeout in seconds of the CURL connection. This timeout is
-      the time that CURL waits for a response from the remote server to
-      get the size of the image to be downloaded. If not set, the
-      default timeout of 5 seconds is used.
+       ``cookie``
+          Send this cookie (it can also be a list of cookies separated by
+          ';') with each outgoing request. Only supported when using
+          protocols such as HTTP which support cookies, otherwise ignored.
 
-   Note that when passing options to qemu explicitly, ``driver`` is the
-   value of <protocol>.
+       ``timeout``
+          Set the timeout in seconds of the CURL connection. This timeout is
+          the time that CURL waits for a response from the remote server to
+          get the size of the image to be downloaded. If not set, the
+          default timeout of 5 seconds is used.
 
-   Example: boot from a remote Fedora 20 live ISO image
+       Note that when passing options to qemu explicitly, ``driver`` is the
+       value of <protocol>.
 
-   .. parsed-literal::
+       Example: boot from a remote Fedora 20 live ISO image
 
-      |qemu_system_x86| --drive media=cdrom,file=https://archives.fedoraproject.org/pub/archive/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
+       .. parsed-literal::
 
-      |qemu_system_x86| --drive media=cdrom,file.driver=http,file.url=http://archives.fedoraproject.org/pub/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
+          |qemu_system_x86| --drive media=cdrom,file=https://archives.fedoraproject.org/pub/archive/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
 
-   Example: boot from a remote Fedora 20 cloud image using a local
-   overlay for writes, copy-on-read, and a readahead of 64k
+          |qemu_system_x86| --drive media=cdrom,file.driver=http,file.url=http://archives.fedoraproject.org/pub/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
 
-   .. parsed-literal::
+       Example: boot from a remote Fedora 20 cloud image using a local
+       overlay for writes, copy-on-read, and a readahead of 64k
 
-      qemu-img create -f qcow2 -o backing_file='json:{"file.driver":"http",, "file.url":"http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/20/Images/x86_64/Fedora-x86_64-20-20131211.1-sda.qcow2",, "file.readahead":"64k"}' /tmp/Fedora-x86_64-20-20131211.1-sda.qcow2
+       .. parsed-literal::
 
-      |qemu_system_x86| -drive file=/tmp/Fedora-x86_64-20-20131211.1-sda.qcow2,copy-on-read=on
+          qemu-img create -f qcow2 -o backing_file='json:{"file.driver":"http",, "file.url":"http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/20/Images/x86_64/Fedora-x86_64-20-20131211.1-sda.qcow2",, "file.readahead":"64k"}' /tmp/Fedora-x86_64-20-20131211.1-sda.qcow2
 
-   Example: boot from an image stored on a VMware vSphere server with a
-   self-signed certificate using a local overlay for writes, a readahead
-   of 64k and a timeout of 10 seconds.
+          |qemu_system_x86| -drive file=/tmp/Fedora-x86_64-20-20131211.1-sda.qcow2,copy-on-read=on
 
-   .. parsed-literal::
+       Example: boot from an image stored on a VMware vSphere server with a
+       self-signed certificate using a local overlay for writes, a readahead
+       of 64k and a timeout of 10 seconds.
+
+       .. parsed-literal::
 
-      qemu-img create -f qcow2 -o backing_file='json:{"file.driver":"https",, "file.url":"https://user:password@vsphere.example.com/folder/test/test-flat.vmdk?dcPath=Datacenter&dsName=datastore1",, "file.sslverify":"off",, "file.readahead":"64k",, "file.timeout":10}' /tmp/test.qcow2
+          qemu-img create -f qcow2 -o backing_file='json:{"file.driver":"https",, "file.url":"https://user:password@vsphere.example.com/folder/test/test-flat.vmdk?dcPath=Datacenter&dsName=datastore1",, "file.sslverify":"off",, "file.readahead":"64k",, "file.timeout":10}' /tmp/test.qcow2
 
-      |qemu_system_x86| -drive file=/tmp/test.qcow2
+          |qemu_system_x86| -drive file=/tmp/test.qcow2
-- 
2.31.1



  parent reply	other threads:[~2022-01-31 17:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-31 17:04 [PATCH 0/5] docs: Don't document disabled features Kevin Wolf
2022-01-31 17:04 ` [PATCH 1/5] docs: Pass disabled configure options to sphinx Kevin Wolf
2022-01-31 17:53   ` Daniel P. Berrangé
2022-01-31 17:04 ` [PATCH 2/5] docs: Only mention iscsi in the man page when available Kevin Wolf
2022-01-31 18:57   ` Peter Maydell
2022-02-01  8:40     ` Kevin Wolf
2022-01-31 17:04 ` [PATCH 3/5] docs: Only mention ssh " Kevin Wolf
2022-01-31 17:04 ` Kevin Wolf [this message]
2022-01-31 17:04 ` [PATCH 5/5] docs: Only mention gluster " Kevin Wolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220131170411.125198-5-kwolf@redhat.com \
    --to=kwolf@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=timao@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).