at 21.11-pre 953 B view raw
1<section xmlns="http://docbook.org/ns/docbook" 2 xmlns:xlink="http://www.w3.org/1999/xlink" 3 xmlns:xi="http://www.w3.org/2001/xinclude" 4 xml:id="sec-prefer-remote-fetch"> 5 <title>prefer-remote-fetch overlay</title> 6 7 <para> 8 <function>prefer-remote-fetch</function> is an overlay that download sources on remote builder. This is useful when the evaluating machine has a slow upload while the builder can fetch faster directly from the source. To use it, put the following snippet as a new overlay: 9<programlisting> 10self: super: 11 (super.prefer-remote-fetch self super) 12</programlisting> 13 A full configuration example for that sets the overlay up for your own account, could look like this 14<screen> 15<prompt>$ </prompt>mkdir ~/.config/nixpkgs/overlays/ 16<prompt>$ </prompt>cat &gt; ~/.config/nixpkgs/overlays/prefer-remote-fetch.nix &lt;&lt;EOF 17 self: super: super.prefer-remote-fetch self super 18EOF 19</screen> 20 </para> 21</section>