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

Some extra_conf arguments are silently ignored #577

Closed
therealpxc opened this issue Jul 17, 2023 · 5 comments
Closed

Some extra_conf arguments are silently ignored #577

therealpxc opened this issue Jul 17, 2023 · 5 comments
Labels
bug Something isn't working

Comments

@therealpxc
Copy link

I've noticed that extra_conf arguments are listed in plans generated, but then don't actually appear in /etc/nix/nix.conf after the install is finished. I've seen this with:

  • any !include ... line
  • overriding extra_conf lines that come by default in the installer, e.g., extra-nix-path

here's a snippet from a plan generated with v0.10.0:

"planner": {
    "planner": "macos",
    "settings": {
      "modify_profile": true,
      "nix_build_group_name": "nixbld",
      "nix_build_group_id": 30000,
      "nix_build_user_prefix": "_nixbld",
      "nix_build_user_count": 32,
      "nix_build_user_id_base": 300,
      "nix_package_url": "https://releases.nixos.org/nix/nix-2.15.0/nix-2.15.0-aarch64-darwin.tar.xz",
      "proxy": null,
      "ssl_cert_file": null,
      "extra_conf": [
        "!include /etc/nix/access-tokens.nix.conf",
        "extra-nix-path = nixpkgs=flake:nixpkgs darwin=flake:nix-darwin darwin-config=/etc/nix-darwin/configuration.nix",
        "auto-optimise-store = false"
      ],
      "force": false,
      "diagnostic_endpoint": "https://install.determinate.systems/nix/diagnostic"
    },
    "encrypt": false,
    "case_sensitive": false,
    "volume_label": "Nix Store",
    "root_disk": null
  }

When I run install instead of plan, it also reports those same features prior to installation:

Configured settings:
* extra_conf: ["!include /etc/nix/access-tokens.nix.conf","extra-nix-path = nixpkgs=flake:nixpkgs darwin=flake:nix-darwin darwin-config=/etc/nix-darwin/configuration.nix","auto-optimise-store = false"]
* root_disk: null
* volume_encrypt: false

but when the install is completed, here is what /etc/nix/nix.conf looks like:

# Generated by https://github.com/DeterminateSystems/nix-installer, version 0.10.0.
extra-nix-path = nixpkgs=flake:nixpkgs
experimental-features = nix-command flakes auto-allocate-uids
auto-optimise-store = true
build-users-group = nixbld
bash-prompt-prefix = (nix:$name)\040
@Hoverbear
Copy link
Contributor

This likely stems from a bug in https://github.com/DeterminateSystems/nix-config-parser, but this issue is just fine living here since we're the only user of that crate.

@Hoverbear Hoverbear added the bug Something isn't working label Jul 17, 2023
@Hoverbear Hoverbear added this to the 0.10.1 milestone Jul 17, 2023
@Hoverbear Hoverbear modified the milestones: 0.11.0, 0.11.1 Aug 10, 2023
@Hoverbear
Copy link
Contributor

#620 may resolve this

@therealpxc
Copy link
Author

I'm traveling atm so it may be a few days before I find time, but I'm excited to test this again! Thanks for the update :)

@Hoverbear Hoverbear modified the milestones: 0.12.0, 0.12.1 Sep 22, 2023
@Hoverbear
Copy link
Contributor

I think this is fixed but I've kicked it along just in case you find an issue!

@Hoverbear Hoverbear modified the milestones: 0.12.1, 0.12.2 Sep 28, 2023
@Hoverbear Hoverbear modified the milestones: 0.13.1, 0.14.1 Oct 16, 2023
@Hoverbear Hoverbear modified the milestones: 0.15.0, 0.15.1 Nov 14, 2023
@Hoverbear
Copy link
Contributor

I believe this may be fixed so I am closing it.

@Hoverbear Hoverbear removed this from the 0.15.2 milestone Dec 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants