]> code.ossystems Code Review - openembedded-core.git/commitdiff
documentation/poky-ref-manual/faq.xml: Added entry about proxy and firewall
authorScott Rifenbark <scott.m.rifenbark@intel.com>
Fri, 18 Mar 2011 14:12:42 +0000 (08:12 -0600)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 18 Mar 2011 17:20:45 +0000 (17:20 +0000)
This is an explanation on how to get by the proxy or around the
firewall when Poky is trying to find and download sources.

Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com>
documentation/poky-ref-manual/faq.xml

index 366db6c41233a44d4387c125f81c7a08d7521e62..f4b5ae0fd10c0b45dba9d4e6578e2ba29ec2acdf 100644 (file)
         </answer>
     </qandaentry>
 
+    <qandaentry>
+        <question>
+            <para>
+                How does Poky obtain source code and will it work behind my firewall or proxy server?
+            </para>
+        </question>
+        <answer>
+            <para>
+                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.
+            </para>
+            <para>
+                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.
+            </para>
+            <para>
+                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.
+            </para>
+            <para>
+                As an example, you could add a specific server for Poky to attempt before any
+                others by adding something like the following to the <filename>local.conf</filename>
+                configuration file:
+                <literallayout class='monospaced'>
+     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"
+                </literallayout>
+            </para>
+            <para>
+                These changes cause Poky to intercept GIT, FTP, HTTP, and HTTPS
+                requests and direct them to the <filename>http://</filename> sources mirror.
+                You can use <filename>file://</filename> urls to point to local directories 
+                or network shares as well.
+            </para>
+            <para>
+                Aside from the previous technique, these options also exist:
+                <literallayout class='monospaced'>
+     BB_NO_NETWORK = "1"
+                </literallayout>
+             </para>
+             <para>
+                 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.
+             </para>
+             <para>
+                 Here is another technique:
+                 <literallayout class='monospaced'>
+     BB_FETCH_PREMIRRORONLY = "1"
+                 </literallayout>
+             </para>
+             <para>
+                 This statement limits Poky to pulling source from the PREMIRRORS only.
+                 Again, this technique is useful for reproducing builds.
+             </para>
+             <para>
+                 Here is another technique:
+                 <literallayout class='monospaced'>
+     BB_GENERATE_MIRROR_TARBALLS = "1"
+                 </literallayout>
+             </para>
+             <para>
+                 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.
+             </para>
+             <para>
+                 Finally, consider an example where you are behind an HTTP-only firewall.
+                 You could make the following changes to the <filename>local.conf</filename>
+                 configuration file as long as the premirror server is up to date:
+                 <literallayout class='monospaced'>
+     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" 
+                 </literallayout>
+             </para>
+             <para>
+                 These changes would cause Poky to successfully fetch source over HTTP and 
+                 any network accesses to anything other than the premirror would fail.
+             </para>
+             <para>
+                 Poky also honors the standard environment variables 
+                 <filename>http_proxy</filename>, <filename>ftp_proxy</filename>, 
+                 <filename>https_proxy</filename>, and <filename>all_proxy</filename>
+                 to redirect requests through proxy servers.
+             </para>
+        </answer>
+    </qandaentry>