Commit Graph

778 Commits

Author SHA1 Message Date
Jörg Thalheim
bc0d87a4f1
Merge pull request #47455 from nyanloutre/steamPackages.steam-udev
steamPackages.steam: add udev rules and update to 1.0.0.56
2018-10-02 00:55:41 +01:00
lewo
56b4db9710
Merge pull request #47411 from graham-at-target/multi-layered-images-crafted
Multi-Layered Docker Images
2018-10-01 09:48:24 +02:00
nyanloutre
d859a66351
nixos/steam-hardware: update documentation 2018-09-30 11:27:47 +02:00
Graham Christensen
d1e46df24b fixup: drop comment about config behaving differently from buildImage 2018-09-27 08:14:04 -04:00
Graham Christensen
4fe9006190 dockerTools.buildLayeredImage: init
Create a many-layered Docker Image.

Implements much less than buildImage:

 - Doesn't support specific uids/gids
 - Doesn't support runninng commands after building
 - Doesn't require qemu
 - Doesn't create mutable copies of the files in the path
 - Doesn't support parent images

If you want those feature, I recommend using buildLayeredImage as an
input to buildImage.

Notably, it does support:

 - Caching low level, common paths based on a graph traversial
   algorithm, see referencesByPopularity in
   0a80233487993256e811f566b1c80a40394c03d6
 - Configurable number of layers. If you're not using AUFS or not
   extending the image, you can specify a larger number of layers at
   build time:

       pkgs.dockerTools.buildLayeredImage {
         name = "hello";
         maxLayers = 128;
         config.Cmd = [ "${pkgs.gitFull}/bin/git" ];
       };

 - Parallelized creation of the layers, improving build speed.
 - The contents of the image includes the closure of the configuration,
   so you don't have to specify paths in contents and config.

   With buildImage, paths referred to by the config were not included
   automatically in the image. Thus, if you wanted to call Git, you
   had to specify it twice:

       pkgs.dockerTools.buildImage {
         name = "hello";
         contents = [ pkgs.gitFull ];
         config.Cmd = [ "${pkgs.gitFull}/bin/git" ];
       };

   buildLayeredImage on the other hand includes the runtime closure of
   the config when calculating the contents of the image:

       pkgs.dockerTools.buildImage {
         name = "hello";
         config.Cmd = [ "${pkgs.gitFull}/bin/git" ];
       };

Minor Problems

 - If any of the store paths change, every layer will be rebuilt in
   the nix-build. However, beacuse the layers are bit-for-bit
   reproducable, when these images are loaded in to Docker they will
   match existing layers and not be imported or uploaded twice.

Common Questions

 - Aren't Docker layers ordered?

   No. People who have used a Dockerfile before assume Docker's
   Layers are inherently ordered. However, this is not true -- Docker
   layers are content-addressable and are not explicitly layered until
   they are composed in to an Image.

 - What happens if I have more than maxLayers of store paths?

   The first (maxLayers-2) most "popular" paths will have their own
   individual layers, then layer #(maxLayers-1) will contain all the
   remaining "unpopular" paths, and finally layer #(maxLayers) will
   contain the Image configuration.
2018-09-26 17:54:14 -04:00
John Ericson
22ce614112
Merge pull request #47238 from obsidiansystems/overrideScope-order
lib: Deprecate `overrideScope` in lieu of `overrideScope'` taking arguments in the conventional order
2018-09-24 18:04:18 -04:00
John Ericson
b9dce11712 lib: Make overrideScope' which takes arguments in the conventional order
The `overrideScope` bound by `makeScope` (via special `callPackage`)
took an override in the form `super: self { … }`. But this is
dangerously close to the `self: super { … }` form used by *everything*
else, even other definitions of `overrideScope`! Since that
implementation did not even share any code either until I changed it
recently in 3cf43547f4, this inconsistency
is almost certainly an oversight and not intentional.

Unfortunately, just as the inconstency is hard to debug if one just
assumes the conventional order, any sudden fix would break existing
overrides in the same hard-to-debug way. So instead of changing the
definition a new `overrideScope'` with the conventional order is added,
and old `overrideScope` deprecated with a warning saying to use
`overrideScope'` instead. That will hopefully get people to stop using
`overrideScope`, freeing our hand to change or remove it in the future.
2018-09-24 17:50:11 -04:00
John Ericson
e39a73cc55 doc: Don't mention top-level {build, host, target}Platform
For technical reasons, we cannot easily add a warning to top-level
definitions, so 2a6e4ae49a and
e51f736076 reverted the deprecation. But
we can still remove mention of the would-be deprecated definitions to
steer people towards using the preferred alternatives.
2018-09-23 13:25:44 -04:00
Graham Christensen
7736337916
Clarfy the binary reproducibility problems of created=now with dockerTools.buildImage. 2018-09-20 20:23:04 -04:00
John Children
aec67d299c doc/stdenv: libaries -> libraries (#47011)
This commit corrects a minor typo in the stdenv portion of the
documentation for the nix language.
2018-09-20 18:45:54 +01:00
Graham Christensen
a32d7e0c74 dockerTools.buildImage: support impure dates
Because dates are an impurity, by default buildImage will use a static
date of one second past the UNIX Epoch. This can be a bit frustrating
when listing docker images in the CLI:

    $ docker image list
    REPOSITORY   TAG      IMAGE ID       CREATED        SIZE
    hello        latest   08c791c7846e   48 years ago   25.2MB

If you want to trade the purity for a better user experience, you can
set created to now.

    pkgs.dockerTools.buildImage {
      name = "hello";
      tag = "latest";
      created = "now";
      contents = pkgs.hello;

      config.Cmd = [ "/bin/hello" ];
    }

and now the Docker CLI will display a reasonable date and sort the
images as expected:

    $ docker image list
    REPOSITORY   TAG      IMAGE ID       CREATED              SIZE
    hello        latest   de2bf4786de6   About a minute ago   25.2MB
2018-09-20 18:26:02 +02:00
Jörg Thalheim
1552f2ef68 doc/vim: remove some vim-plug redundancy 2018-09-20 08:20:11 +01:00
Roman Volosatovs
c1d8b1e266
doc: Add section about vim-plug 2018-09-20 09:05:33 +02:00
Maximilian Bosch
dee2dab7c6
ibus-engines.typing-booster: init at 2.1.1
This package providesa completion input method for faster typing.
See https://mike-fabian.github.io/ibus-typing-booster

Detailed instructions how to activate this IBus engine on your desktop
can be found in the upstream docs: https://mike-fabian.github.io/ibus-typing-booster/documentation.html

A simple VM with the Gnome3 desktop and activated `ibus' looks like
this:

```nix
{
  emojipicker = { pkgs, ... }: {
    services.xserver = {
      enable = true;
      desktopManager.gnome3.enable = true;
      desktopManager.xterm.enable = false;
    };
    users.extraUsers.vm = {
      password = "vm";
      isNormalUser = true;
    };
    i18n.inputMethod.ibus.engines = [
      pkgs.ibus-engines.typing-booster
    ];
    i18n.inputMethod.enabled = "ibus";
    virtualisation.memorySize = 2048;
  };
}
```

Fixes #38721
2018-09-19 21:27:10 +02:00
worldofpeace
6dae5de436
rust.section.md: remove nixcrate reference
nixcrate is deprecated
2018-09-15 18:38:26 +00:00
Sarah Brofeldt
2a6e4ae49a Revert "top-level: Deprecate top-level {build,host,target}Platform"
This reverts commit e51f736076.
2018-09-11 13:25:50 +02:00
Jörg Thalheim
953199fd82 vim-plugins: rewrite updater
A new python script has been added to replace the aged viml-based
updater. The new updater has the following advantages:

- use rss feeds to check for updates quicker
- parallel downloads & better caching
- uses proper override mechanism instead of text substitution
- update generated files in-place instead of having to insert updated plugins manually

Automatically reading `dependencies` from the plugins directory has been
not re-implemented.
This has been mostly been used by Mark Weber's plugins, which seem to
no longer receive regular updates.
This could be implemented in future as required.
2018-09-09 11:22:43 +01:00
Jörg Thalheim
97acac9a81 doc/vim: improve plugin documentation 2018-09-09 09:45:45 +01:00
Timo Kaufmann
e326c0156d
Merge pull request #45728 from Ma27/nixos/weechat-module
nixos/weechat: add module
2018-09-07 17:19:46 +02:00
Maximilian Bosch
a8efe61412
weechat: 2.1 -> 2.2; improve package configuration
This aims to make the `weechat` package even more configurable. It
allows to specify scripts and commands using the `configure` function
inside a `weechat.override` expression.

The package can be configured like this:

```
with import <nixpkgs> { };
weechat.override {
  plugins = { availablePlugins, ... }: {
    plugins = builtins.attrValues availablePlugins;

    init = ''
      /set foo bar
      /server add freenode chat.freenode.org
    '';

    scripts = [ "/path/to/script.py" ];
  };
}
```

All commands are passed to `weechat --run-command "/set foo bar;/server ..."`.

The `plugins' attribute is not necessarily required anymore, if it's
sufficient to add `init' commands, the `plugins' will be
`builtins.attrValues availablePlugins' by default.

Additionally the result contains `weechat` and `weechat-headless`
(introduced in WeeChat 2.1) now.
2018-09-07 13:10:43 +02:00
John Ericson
0af9072e74
Merge pull request #46059 from obsidiansystems/deprecate-top-level-platform-aliases
top-level: Deprecate top-level `{build,host,target}Platform`
2018-09-06 07:52:17 -04:00
John Ericson
e51f736076 top-level: Deprecate top-level {build,host,target}Platform
I don't know when we can/should remove them, but this at least gets
people to stop using them. The preferred alternatives also date back to
17.09 so writing forward-compatable code without extra conditions is
easy.

Beginning with these as they are the least controversial.
2018-09-05 11:53:51 -04:00
Eelco Dolstra
eac06ed070
Manual: Random indentation fixes 2018-09-03 17:13:46 +02:00
Graham Christensen
03b89e3031
Merge pull request #45914 from grahamc/section-ids
Section ids
2018-09-01 15:38:52 -04:00
Graham Christensen
2eea92a1dc
nixpkgs docs: give linked things IDs 2018-09-01 15:20:57 -04:00
Graham Christensen
cbdcf81590
Add section IDs 2018-09-01 15:06:38 -04:00
Jörg Thalheim
4a74aca868
Merge pull request #45700 from Mic92/node-packages-v8
nodePackages: 6_x -> 8_x
2018-09-01 09:09:24 +01:00
Daiderd Jordan
477efb9d87
Merge pull request #42464 from LnL7/manual-installcheck
doc: add installCheckTarget and installCheckFlags to manual
2018-08-31 20:08:16 +02:00
John Ericson
2c4a75e9ef
Merge pull request #45820 from obsidiansystems/dont-use-obsolete-platform-aliases
treewide: Dont use obsolete platform aliases
2018-08-31 09:56:10 -04:00
Jörg Thalheim
86bd041196 docs/python: fix attribute naming example
https://github.com/NixOS/nixpkgs/pull/45822#issuecomment-417566642
2018-08-31 08:02:55 +01:00
Jörg Thalheim
e5124b0f75 doc/python: convention for attributes names
cc @FRidh, @dotlambda
2018-08-31 06:52:53 +01:00
John Ericson
0828e2d8c3 treewide: Remove usage of remaining redundant platform compatability stuff
Want to get this out of here for 18.09, so it can be deprecated
thereafter.
2018-08-30 17:20:32 -04:00
John Ericson
2c2f1e37d4 reewide: Purge all uses stdenv.system and top-level system
It is deprecated and will be removed after 18.09.
2018-08-30 17:20:32 -04:00
Jörg Thalheim
bf56bc7b49 nodePackages: 6_x -> 8_x 2018-08-28 11:15:07 +01:00
Graham Christensen
360f420ac7
nixpkgs docs: normalize 2018-08-27 19:54:41 -04:00
Graham Christensen
53371b15c6
docs: include shell section 2018-08-27 19:53:25 -04:00
Frederik Rietdijk
b7e0c40d29 docs python: python.buildEnv does not include buildPythonApplication modules
Clarify the issue encountered at
https://github.com/NixOS/nixpkgs/issues/45503
2018-08-26 09:31:39 +02:00
Ryan Mulligan
5c5baaf17d treewide: remove mailing list references 2018-08-23 09:24:44 -07:00
Vladimír Čunát
209730208a
Merge branch 'staging-next' 2018-08-17 20:51:31 +02:00
Florian Klink
e84e2fb434 docs: explain the home passthru present in all JDKs and setting JAVA_HOME where required 2018-08-17 17:06:05 +02:00
Florian Klink
43905b1e0c docs: explain what jdk really points to and why 2018-08-17 16:51:02 +02:00
Vladimír Čunát
cbabebcc2e
Merge branch 'master' into staging-next
Hydra: ?compare=1473892
2018-08-17 13:45:21 +02:00
Jörg Thalheim
78777fbd6b
Merge pull request #44981 from Ekleog/rust-patch-bis
buildRustPackage: allow patches to fix Cargo.lock
2018-08-14 14:23:51 +02:00
Léo Gaspard
af960e5df9
buildRustPackage: add documentation about cargoPatches 2018-08-14 20:09:45 +09:00
Vladimír Čunát
5b0398dc36
Merge branch 'master' into staging-next
Conflicts: gobby and libinfinity - I took the hand-edited versions
instead of those resuting from the mass-replacement.

Hydra: ?compare=1473190
2018-08-13 20:43:59 +02:00
Carlos D
0e7a34a1aa docs: add some docs for hackage2nix 2018-08-13 14:46:11 +10:00
Frederik Rietdijk
d9fa74ba78 Merge master into staging 2018-08-09 18:28:15 +02:00
Frederik Rietdijk
786cbba7be
Merge pull request #44447 from NixOS/staging-next
Staging next
2018-08-09 09:04:03 +02:00
Maximilian Bosch
eb0207f132 citrix_receiver: document installation pitfalls and extraCerts (#44635)
Since #44522 it's possible to specify custom certificates for the Citrix
receiver. As it took me some time to create a proper setup Citrix can
behave fairly unexpected.

I mostly covered two aspects:

* Don't install Citrix with `nix run`: when `citrix.desktop` is linked
  to $XDG_CONFIG_DIRS, it's possible to start a session directly from the
  browser when loading `.ica` files which makes the usage *way* easier.

* It's possible to add custom certificates using the Citrix wrapper. A
  new store path with the original derivation and the certificates will be
  created and therefore no rebuild of the package is needed when adding
  new certs.
2018-08-07 23:48:02 +02:00
Vladimír Čunát
f504af072b
Merge branch 'master' into staging-next
There's been some large rebuild on master.
I don't really have time ATM to find what it was.
2018-08-06 12:07:37 +02:00
Sarah Brofeldt
c6a4f9af60
Merge pull request #44528 from samueldr/fix/mention-bot
doc: Fixes mentions of mention-bot.
2018-08-06 08:59:10 +02:00
Samuel Dionne-Riel
e97112bdc3 doc: Fixes mentions of mention-bot.
Its last mention was on 2017-09-25. Close to a year.

The CODEOWNERS feature of github, though, fills in the gap in a more
appropriate manner (IMHO).
2018-08-05 20:22:32 -04:00
Tuomas Tynkkynen
008fd5fcf5 Merge remote-tracking branch 'upstream/master' into staging 2018-08-04 15:17:42 +03:00
Frederik Rietdijk
699e0e50b7 Merge master into staging-next 2018-08-04 11:43:54 +02:00
John Ericson
7a337cde31
Merge pull request #44423 from obsidiansystems/configureFlags-cleanup
treewide: All configureFlags are lists
2018-08-03 17:49:01 -04:00
John Ericson
db965063b3 treewide: Make configureFlags lists 2018-08-03 17:06:03 -04:00
Matthew Harm Bekkema
a6c7132abc doc: change git:// links to https:// (#44395)
The server is not verified over the git:// transfer protocol. If you
clone a repository over git://, you should check if the latest commit's
hash is correct.

On the other hand, https:// will always verify the server automatically,
using certificate authorities.
2018-08-03 14:01:34 +01:00
John Ericson
89c21fce3f Merge commit 'master' into staging 2018-08-02 16:13:33 -04:00
Daiderd Jordan
61a1b20d23
doc: add darwin installCheckTarget example 2018-08-01 20:58:45 +02:00
James Deikun
bd63de114e stdenv/build-support: support .tbz and .txz tarballs 2018-07-30 15:30:16 -04:00
Nick Novitski
c58b11d229 dockerTools.pullImage: control OS and architecture 2018-07-27 12:29:31 -07:00
Erik Arvstedt
eb60a87887 python-docs: minor typo and grammar fixes 2018-07-26 14:28:23 +02:00
Erik Arvstedt
fa01100f40 python-docs: fix override examples
Use example package `zerobin` instead of `bepasty-server` which
is no longer part of python-packages.
This fixes the examples for current nixpkgs versions.
2018-07-25 21:33:48 +02:00
Erik Arvstedt
42e3727aa2 python docs: improve override example
1. Use the same approach like in the overlay example:
   Override `python` instead of `pythonPackages` so that
   `python.pkgs` refers to the new package set like `pythonPackages`.

   This also fixes a bug in the original example where
   `pkgs.fetchgit` was not in scope.

   Add an extra example to illustrate how to override just a
   package set.

2. Fix mix-up between `super` and `self` in the explanation text.
   Also, simplify the explanation.
2018-07-25 21:29:25 +02:00
Erik Arvstedt
a8f54972f4 python docs: improve overlay example
The `pythonPackages` definition is redundant
2018-07-25 16:44:56 +02:00
Alyssa Ross
9e1e63ce0e doc: add missing semicolon to weechat example (#44003) 2018-07-23 10:48:11 +01:00
Frederik Rietdijk
1a6af9f88e
Merge pull request #43857 from volth/unused
[bot] treewide: remove unreferenced code
2018-07-20 21:06:32 +02:00
volth
87f5930c3f [bot]: remove unreferenced code 2018-07-20 18:48:37 +00:00
Matthew Bauer
76999cc40e treewide: remove aliases in nixpkgs
This makes the command ‘nix-env -qa -f. --arg config '{skipAliases =
true;}'’ work in Nixpkgs.

Misc...

- qtikz: use libsForQt5.callPackage

  This ensures we get the right poppler.

- rewrites:

  docbook5_xsl -> docbook_xsl_ns
  docbook_xml_xslt -> docbook_xsl

diffpdf: fixup
2018-07-18 23:25:20 -04:00
Jan Path
1d3a41a71a Fix invalid sentence in doc (#43228) 2018-07-08 23:46:34 +02:00
worldofpeace
3662ca7500
nixpkgs docs: correct misspell 2018-07-06 15:52:19 +00:00
Mathias Schreck
39e678e24e dockerTools.buildImage: add option to use nix output hash as tag 2018-07-06 15:15:09 +02:00
Alyssa Ross
79ab3370ed manual: fix buildPythonPackage example (#42866) 2018-07-03 17:19:18 +02:00
Matthew Pickering
11551f06e2
Update Python documentation overlay
Using a recursive attribute set is not recommended.
2018-06-30 16:35:49 +01:00
Ryan Mulligan
1d54dc6841 treewide: http -> https 2018-06-29 17:18:27 -07:00
Matthew Bauer
ba87c0ffdb
Merge pull request #41600 from mbbx6spp/docs/add-developPackage-haskell-docs
documentation: add sub-section for the nixpkgs manual Haskell section
2018-06-28 20:39:42 -04:00
Ryan Mulligan
fce8f26af6 treewide: http -> https (#42665) 2018-06-27 22:12:57 +02:00
Frederik Rietdijk
7c9d95fef5 python37: init at 3.7.0rc1 2018-06-25 10:41:32 +02:00
Daiderd Jordan
8500e28d7b
doc: add installCheckTarget and installCheckFlags to manual
Fixes #42393
2018-06-23 21:24:52 +02:00
Susan Potter
a15d310168
documentation: add sub-section for the nixpkgs manual Haskell section 2018-06-21 15:00:01 -05:00
Anders Riutta
085bf3e7b9 docs: minor rewording for easier reading. 2018-06-18 16:02:17 -07:00
Matthew Bauer
d203ce230b haskell.section.md: fix typo 2018-06-16 20:14:51 -04:00
Sarah Brofeldt
f4df5d63f1
Merge pull request #33217 from toonn/master
haskell docs: add info about hoogle's --local flag to section 9.5.2.3
2018-06-12 23:42:54 +02:00
Rolf Schröder
979ac47cd8 doc/languages-frameworks/python.section.md: fix typo (#41824) 2018-06-11 10:24:07 +01:00
Daiderd Jordan
75601e10cb manual: make epub a build product on hydra (#41475) 2018-06-06 22:36:17 +02:00
Samuel Dionne-Riel
6bf54191fb doc: Fixes squishedtogether definitions. 2018-05-31 21:09:35 -04:00
Samuel Dionne-Riel
a45edd9024 doc: ran make format
With visual inspection that nothing got worse.
2018-05-31 21:03:37 -04:00
Samuel Dionne-Riel
bc0421c4cf doc: Adds xml fixing script. (see previous and next commits)
This script is used to automatically fix issues within xml documentation
files.

The script is *for now* intended to be used ad-hoc, and the commits to
be examined.

A future discussion will define whether:

  * This commit and scripts are kept.
  * The script is extended for common use.

The biggest issue right now with the script is that it *could* in theory
destroy a valid space-less varlistentry.

The script could, in practical use, be changed and extended to normalize
some parts of the XML files, mainly:

  * A common quoting style for attributes
  * Fix-up some weird formatting automatically that xmlformat doesn't
    catch
2018-05-31 21:02:15 -04:00
Frederik Rietdijk
39e9de1b85 Docs: improve Python section
Explain `toPythonApplication` and `toPythonModule` as well as some minor improvements.
2018-05-30 19:08:06 +02:00
John Ericson
18742471af Merge remote-tracking branch 'upstream/master' into staging
Use newer vagrant from master
2018-05-23 09:40:37 -04:00
Dmitry Kalinkin
3dd6350420
doc: use "with stdenv.lib" in meta 2018-05-22 13:25:09 -04:00
Josef Kemetmüller
a28c4a5396 perlPackages.BerkeleyDB: fix db dependency
This fixes a regression introduced in 4b06383.

[dezgeg squashed in to fit the changes introduced in "db: Use more
conventional outputs, also split bin"]
2018-05-22 17:49:04 +03:00
toonn
6caf7c9d85 Flipped URI slashes 2018-05-22 13:12:43 +02:00
toonn
c17061efd4 haskell docs: add explanation of what the --local flag does and the service 2018-05-22 13:12:43 +02:00
toonn
ae1e304a60 haskell docs: add info about hoogle's --local flag to section 9.5.2.3
Relevant section: 9.5.2.3. How to install a compiler with libraries, hoogle and documentation indexes

Since version 5 `hoogle server`s --local flag solves the problem with links from
`http:` to `file:` URIs:

    hoogle server --local -p 8080
2018-05-22 13:10:57 +02:00
John Ericson
8e891e6ed4 Merge remote-tracking branch 'upstream/master' into staging 2018-05-14 10:57:33 -04:00
Ben Creasy
18ae1b6d31 docs: fix broken link to staging policy 2018-05-13 23:23:44 -07:00
John Ericson
81387c2e78 Merge remote-tracking branch 'upstream/master' into staging 2018-05-11 17:12:04 -04:00
Scott Trinh
7c2d43f3f9 Fix small typo in configuration documentation (#40357)
* Fix small typo in configuration documentation
* doc: Fix second instance of same typo
2018-05-11 21:31:56 +02:00
John Ericson
cf06e42d1c Merge remote-tracking branch 'upstream/master' into staging 2018-05-03 16:35:36 -04:00