all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Efraim Flashner <efraim@flashner.co.il>
To: Jonathan Frederickson <jonathan@terracrypt.net>
Cc: help-guix@gnu.org
Subject: Re: Offloading builds asynchronously for use by low-powered machines (or: can you get a home config derivation without building its packages?)
Date: Thu, 26 Dec 2024 16:33:17 +0200	[thread overview]
Message-ID: <Z21pLZm5CvXKPKa3@3900XT> (raw)
In-Reply-To: <1f6cc191-0347-4447-892a-9807674bf625@app.fastmail.com>

[-- Attachment #1: Type: text/plain, Size: 2879 bytes --]

On Tue, Dec 24, 2024 at 02:38:59PM -0500, Jonathan Frederickson wrote:
> Hi - I've been using Guix on a couple slower aarch64 machines for a while. One of the recurring pain points with doing so has been that very often, when I go to build my home environment after a fresh 'guix pull', most of the packages in it do not yet have substitutes built.
> 
> I do also have a couple more powerful aarch64 machines available, so build offloading is an option. However, one of the machines I use most frequently is a small laptop (the MNT Pocket Reform), which is meant to be very portable. Even on my more powerful machines, building everything in my home environment when no (or very few) substitutes are available may take multiple hours or sometimes days, and build offloading being synchronous means the machine needs to maintain a constant connection to the build servers during a build. This is very inconvenient for a portable machine!
> 
> What I would *like* to be able to do is to trigger a build on another more powerful machine asynchronously, and then later come back and build my home environment using the substitutes from that build. The Guix Build Coordinator seems like it may serve my needs fairly well based on the description in this blog post: https://guix.gnu.org/en/blog/2021/building-derivations-how-complicated-can-it-be/
> 
> ...but in contrast to building a specific package with 'guix build', it doesn't look like I'm able to get the derivation path for a home configuration without first building the packages! Running 'guix build -d -f /path/to/home/config' attempts to build the packages in my home configuration if they're not yet built, rather than returning a derivation that I could submit to the build coordinator.
> 
> I admit that I don't fully grok derivations yet; is this inevitable for derivations, or is it just a limitation of 'guix build' and is there actually a way to get at the home configuration derivation prior to building its packages?
> 
> Thanks,
> - jfred

I have a pinebook pro and I also have a couple of other aarch64
machines, and here's what I do:

`guix pull` on my pinebook pro, `guix home build --no-grafts ... -d` and
`guix system build --no-grafts -d` to get the derivations

Then I'll do `guix copy --to=my-x86_64-machine /gnu/store/...-drv` of
the two derivations

Then from there I'll build them since I already have offloading setup.

I'll either get substitutes from my main machine, or from there I'll do
`guix copy --to=pinebookpro $(guix build /gnu/store/...-drv)`, and
that'll automatically copy the packages to my pinebook pro once it's
finished building everything.

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2024-12-26 14:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-24 19:38 Offloading builds asynchronously for use by low-powered machines (or: can you get a home config derivation without building its packages?) Jonathan Frederickson
2024-12-26 14:33 ` Efraim Flashner [this message]
2024-12-27 22:10   ` Jonathan Frederickson

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=Z21pLZm5CvXKPKa3@3900XT \
    --to=efraim@flashner.co.il \
    --cc=help-guix@gnu.org \
    --cc=jonathan@terracrypt.net \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.