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

Add --no-net flag #2949

Merged
merged 4 commits into from Jun 18, 2019
Merged

Add --no-net flag #2949

merged 4 commits into from Jun 18, 2019

Conversation

edolstra
Copy link
Member

This flag

  • Disables substituters.

  • Sets the tarball-ttl to infinity (ensuring e.g. that the flake registry and any downloaded flakes are considered current).

  • Disables retrying downloads and sets the connection timeout to the minimum. (So it doesn't completely disable downloads at the moment.)

--no-net is implied if there are no configured non-loopback/link-local IPv4/v6 addresses.

This makes commands like 'nix run nixpkgs.chromium' work again.
This flag

* Disables substituters.

* Sets the tarball-ttl to infinity (ensuring e.g. that the flake
  registry and any downloaded flakes are considered current).

* Disables retrying downloads and sets the connection timeout to the
  minimum. (So it doesn't completely disable downloads at the moment.)
This ensures that "nix" shows warnings. Previously these were hidden
because they were at "info" level.
@edolstra edolstra requested a review from grahamc June 18, 2019 08:05
@edolstra edolstra merged commit 3871131 into flakes Jun 18, 2019
@edolstra edolstra deleted the no-net branch June 21, 2019 15:36
infinisil added a commit to infinisil/nixpkgs that referenced this pull request Sep 28, 2019
Since version 2.3 (NixOS/nix#2949 which was
cherry-picked to master) Nix issues a warning when --no-net wasn't
passed and there is no network interface. This commit adds the --no-net
flag to the nix.conf check such that no warning is issued.
infinisil added a commit to NixOS/nixpkgs that referenced this pull request Oct 2, 2019
Since version 2.3 (NixOS/nix#2949 which was
cherry-picked to master) Nix issues a warning when --no-net wasn't
passed and there is no network interface. This commit adds the --no-net
flag to the nix.conf check such that no warning is issued.

(cherry picked from commit e463c7c)
dtzWill pushed a commit to dtzWill/nixpkgs that referenced this pull request Oct 3, 2019
Since version 2.3 (NixOS/nix#2949 which was
cherry-picked to master) Nix issues a warning when --no-net wasn't
passed and there is no network interface. This commit adds the --no-net
flag to the nix.conf check such that no warning is issued.

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

Successfully merging this pull request may close these issues.

None yet

1 participant