Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only set buildMachinesFiles when nix.buildMachines is defined #432

Merged
merged 1 commit into from Sep 24, 2019

Conversation

basvandijk
Copy link
Member

@basvandijk basvandijk commented Dec 11, 2016

This should fix #430.

We should set buildMachinesFiles to [ "/etc/nix/machines" ]only when nix.buildMachines is set to a non-empty list because that causes that file to be generated.

This should also be applied to <nixpkgs/nixos/modules/services/continuous-integration/hydra/default.nix>.

@domenkozar
Copy link
Member

@edolstra

@joepie91
Copy link

Any reason this is not being reviewed/merged? Just ran into this issue with a self-contained Hydra installation, and it seems like a relatively simple change to apply.

@grahamc
Copy link
Member

grahamc commented Mar 18, 2019

One reason might be hydra.nixos.org's build machines file is managed manually, and this would change that behavior some.

@basvandijk
Copy link
Member Author

In the process of working on #665 I was bitten by this again. I spend the best part of an hour figuring out why my jobs weren't being build until I remembered this PR.

If hydra.nixos.org is manually managing /etc/nix/machine wouldn't it make more sense to explicitly set services.hydra.buildMachinesFiles = [ "/etc/nix/machines" ] on hydra.nixos.org and not rely on the default?

@edolstra edolstra merged commit 4223202 into NixOS:master Sep 24, 2019
basvandijk added a commit to basvandijk/nixpkgs that referenced this pull request Jan 14, 2020
This applies [hydra PR NixOS#432](NixOS/hydra#432)
to the NixOS module in nixpkgs:

```
commit 4efd078977e5ea20e1104783efc324cba11690bc
Author: Bas van Dijk <v.dijk.bas@gmail.com>
Date:   Sun Dec 11 15:35:38 2016 +0100

    Only set buildMachinesFiles when nix.buildMachines is defined
```
dtzWill pushed a commit to dtzWill/nixpkgs that referenced this pull request Jan 15, 2020
This applies [hydra PR NixOS#432](NixOS/hydra#432)
to the NixOS module in nixpkgs:

```
commit 4efd078977e5ea20e1104783efc324cba11690bc
Author: Bas van Dijk <v.dijk.bas@gmail.com>
Date:   Sun Dec 11 15:35:38 2016 +0100

    Only set buildMachinesFiles when nix.buildMachines is defined
```

(cherry picked from commit ad554b3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

For a self-contained instance, nix.buildMachines must be set but this isn't documented
5 participants