diff --git a/documentation/poky-ref-manual/faq.xml b/documentation/poky-ref-manual/faq.xml index 366db6c412..f4b5ae0fd1 100644 --- a/documentation/poky-ref-manual/faq.xml +++ b/documentation/poky-ref-manual/faq.xml @@ -413,6 +413,102 @@ + + + + How does Poky obtain source code and will it work behind my firewall or proxy server? + + + + + The way Poky obtains source code is highly configurable. + You can setup Poky to get source code in most environmnents if + HTTP transport is available. + + + When Poky searches for source code it first tries the local download directory. + If that location fails, Poky tries PREMIRRORS, the upstream source, + and then MIRRORS in that order. + + + By default, Poky uses the Yocto Project source PREMIRRORS for SCM-based sources, + upstreams for normal tarballs and then falls back to a number of other mirrors + including the Yocto Project source mirror if those fail. + + + As an example, you could add a specific server for Poky to attempt before any + others by adding something like the following to the local.conf + configuration file: + + PREMIRRORS_prepend = "\ + git://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \ + ftp://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \ + http://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \ + https://.*/.* http://autobuilder.yoctoproject.org/sources/ \n" + + + + These changes cause Poky to intercept GIT, FTP, HTTP, and HTTPS + requests and direct them to the http:// sources mirror. + You can use file:// urls to point to local directories + or network shares as well. + + + Aside from the previous technique, these options also exist: + + BB_NO_NETWORK = "1" + + + + This statement tells BitBake to throw an error instead of trying to access the + Internet. + This technique is useful if you want to ensure code builds only from local sources. + + + Here is another technique: + + BB_FETCH_PREMIRRORONLY = "1" + + + + This statement limits Poky to pulling source from the PREMIRRORS only. + Again, this technique is useful for reproducing builds. + + + Here is another technique: + + BB_GENERATE_MIRROR_TARBALLS = "1" + + + + This statement tells Poky to generate mirror tarballs. + This technique is useful if you want to create a mirror server. + If not, however, the technique can simply waste time during the build. + + + Finally, consider an example where you are behind an HTTP-only firewall. + You could make the following changes to the local.conf + configuration file as long as the premirror server is up to date: + + PREMIRRORS_prepend = "\ + ftp://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \ + http://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \ + https://.*/.* http://autobuilder.yoctoproject.org/sources/ \n" + BB_FETCH_PREMIRRORONLY = "1" + + + + These changes would cause Poky to successfully fetch source over HTTP and + any network accesses to anything other than the premirror would fail. + + + Poky also honors the standard environment variables + http_proxy, ftp_proxy, + https_proxy, and all_proxy + to redirect requests through proxy servers. + + +