Skip to content

Improve error message when missing remote building feature forbids build #2238

@nh2

Description

@nh2

I tried today to build a big package (chromium) remotely on a powerful machine with

nix-store --realise --builders 'ssh://[email protected] x86_64-linux' /nix/store/i0kwyxpihg1gcp9jg4qwp7qcrpagj818-chromium-67.0.3396.87.drv /nix/store/bmigs53iryqpqjsy5w4qjfndlh6hxbms-chromium-67.0.3396.87.drv

but it would build only locally. Trying to force the remote build with -j0:

nix-store --realise --builders 'ssh://[email protected] x86_64-linux' -j0 /nix/store/i0kwyxpihg1gcp9jg4qwp7qcrpagj818-chromium-67.0.3396.87.drv /nix/store/bmigs53iryqpqjsy5w4qjfndlh6hxbms-chromium-67.0.3396.87.drv

got me:

unable to start any build; either increase '--max-jobs' or enable remote builds

But I have remote build enabled -- --builders is given right there!

On IRC I learned that it's because chromium has requiredSystemFeatures = [ "big-parallel" ];, and I need to declare that my remote machine is big-parallel.

Solution:

nix-store --realise --builders 'ssh://[email protected] x86_64-linux - - - big-parallel' -j0 /nix/store/i0kwyxpihg1gcp9jg4qwp7qcrpagj818-chromium-67.0.3396.87.drv /nix/store/bmigs53iryqpqjsy5w4qjfndlh6hxbms-chromium-67.0.3396.87.drv

But ideally we would improve the error message, perhaps

  • not suggesting or enable remote builds when it's enabled
  • printing a helpful warning/info message when when a builder with fitting architecture isn't selected just because it doesn't have a special flag like big-parallel

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions