diff options
Diffstat (limited to 'bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst')
-rw-r--r-- | bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst | 57 |
1 files changed, 51 insertions, 6 deletions
diff --git a/bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst b/bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst index 4dfb7889e8..fb4f0a23d7 100644 --- a/bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst +++ b/bitbake/doc/bitbake-user-manual/bitbake-user-manual-fetching.rst @@ -424,8 +424,8 @@ This fetcher supports the following parameters: - *"nobranch":* Tells the fetcher to not check the SHA validation for the branch when set to "1". The default is "0". Set this option for - the recipe that refers to the commit that is valid for a tag instead - of the branch. + the recipe that refers to the commit that is valid for any namespace + (branch, tag, ...) instead of the branch. - *"bareclone":* Tells the fetcher to clone a bare clone into the destination directory without checking out a working tree. Only the @@ -476,6 +476,14 @@ Here are some example URLs:: easy to share metadata without removing passwords. SSH keys, ``~/.netrc`` and ``~/.ssh/config`` files can be used as alternatives. +Using tags with the git fetcher may cause surprising behaviour. Bitbake needs to +resolve the tag to a specific revision and to do that, it has to connect to and use +the upstream repository. This is because the revision the tags point at can change and +we've seen cases of this happening in well known public repositories. This can mean +many more network connections than expected and recipes may be reparsed at every build. +Source mirrors will also be bypassed as the upstream repository is the only source +of truth to resolve the revision accurately. For these reasons, whilst the fetcher +can support tags, we recommend being specific about revisions in recipes. .. _gitsm-fetcher: @@ -688,6 +696,41 @@ Here is an example URL:: It can also be used when setting mirrors definitions using the :term:`PREMIRRORS` variable. +.. _gcp-fetcher: + +GCP Fetcher (``gs://``) +-------------------------- + +This submodule fetches data from a +`Google Cloud Storage Bucket <https://cloud.google.com/storage/docs/buckets>`__. +It uses the `Google Cloud Storage Python Client <https://cloud.google.com/python/docs/reference/storage/latest>`__ +to check the status of objects in the bucket and download them. +The use of the Python client makes it substantially faster than using command +line tools such as gsutil. + +The fetcher requires the Google Cloud Storage Python Client to be installed, along +with the gsutil tool. + +The fetcher requires that the machine has valid credentials for accessing the +chosen bucket. Instructions for authentication can be found in the +`Google Cloud documentation <https://cloud.google.com/docs/authentication/provide-credentials-adc#local-dev>`__. + +If it used from the OpenEmbedded build system, the fetcher can be used for +fetching sstate artifacts from a GCS bucket by specifying the +``SSTATE_MIRRORS`` variable as shown below:: + + SSTATE_MIRRORS ?= "\ + file://.* gs://<bucket name>/PATH \ + " + +The fetcher can also be used in recipes:: + + SRC_URI = "gs://<bucket name>/<foo_container>/<bar_file>" + +However, the checksum of the file should be also be provided:: + + SRC_URI[sha256sum] = "<sha256 string>" + .. _crate-fetcher: Crate Fetcher (``crate://``) @@ -717,7 +760,7 @@ Javascript package registry. The format for the :term:`SRC_URI` setting must be:: - SRC_URI = "npm://some.registry.url;OptionA=xxx;OptionB=xxx;..." + SRC_URI = "npm://some.registry.url;ParameterA=xxx;ParameterB=xxx;..." This fetcher supports the following parameters: @@ -740,7 +783,7 @@ Here is an example URL with both fetchers:: " See :yocto_docs:`Creating Node Package Manager (NPM) Packages -</dev-manual/common-tasks.html#creating-node-package-manager-npm-packages>` +</dev-manual/packages.html#creating-node-package-manager-npm-packages>` in the Yocto Project manual for details about using :yocto_docs:`devtool <https://docs.yoctoproject.org/ref-manual/devtool-reference.html>` to automatically create a recipe from an NPM URL. @@ -757,7 +800,7 @@ of an NPM package while locking their versions. The format for the :term:`SRC_URI` setting must be:: - SRC_URI = "npmsw://some.registry.url;OptionA=xxx;OptionB=xxx;..." + SRC_URI = "npmsw://some.registry.url;ParameterA=xxx;ParameterB=xxx;..." This fetcher supports the following parameters: @@ -777,7 +820,7 @@ the package which has such dependencies, for example:: Such a file can automatically be generated using :yocto_docs:`devtool <https://docs.yoctoproject.org/ref-manual/devtool-reference.html>` as described in the :yocto_docs:`Creating Node Package Manager (NPM) Packages -</dev-manual/common-tasks.html#creating-node-package-manager-npm-packages>` +</dev-manual/packages.html#creating-node-package-manager-npm-packages>` section of the Yocto Project. Other Fetchers @@ -791,6 +834,8 @@ Fetch submodules also exist for the following: - OSC (``osc://``) +- S3 (``s3://``) + - Secure FTP (``sftp://``) - Secure Shell (``ssh://``) |