Branch: refs/heads/nixpart
  Home:   https://github.com/NixOS/nixpkgs
  Commit: c4698167e12c5bf8c8d201dc0d2c4b25dcfcaede
      
https://github.com/NixOS/nixpkgs/commit/c4698167e12c5bf8c8d201dc0d2c4b25dcfcaede
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-06 (Fri, 06 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/default.nix

  Log Message:
  -----------
  nixos/storage: Generate UUID for each device spec

We want to have deterministic UUIDs for every device specification in
order to avoid the need to manually set labels all over the place.

Of course, we could internally set labels instead of precomputing UUIDs,
but labels have different length restrictions for every file system (for
example XFS has a maximum of 12 bytes, for ext4 it's 16 bytes). In
addition to that we remove the ability for people to set their own
labels during runtime.

The UUIDs generated here are based on version 5:

https://tools.ietf.org/html/rfc4122#section-4.1.3

Our variant deviates from this a bit in that we use string concatenation
to build up the input for the SHA1 hash instead of binaries. The results
however are pretty much the same and in our part the most important
aspect is determinism rather than having a truly unique value across the
whole planet.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 17d464b9f77f90ce319efc5b91a96489e15ae7ff
      
https://github.com/NixOS/nixpkgs/commit/17d464b9f77f90ce319efc5b91a96489e15ae7ff
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-06 (Fri, 06 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/default.nix
    M nixos/modules/tasks/storage/lib.nix

  Log Message:
  -----------
  nixos/storage: Switch to a new mkDeviceSpecOption

Having just a single type for a device specification doesn't work out
well if we want to have an apply function, which we do want, because it
makes more sense if we want to resolve such a device specification
without using builtins.match all over the place.

It also improves a lot in readability of the option descriptions,
because every such option now has not only a description of what a
device specification is but also lists the valid types for the device
specification.

This has another advantage that instead for something like the
following:

Type: list of device specification of <type>.<name>s

The type description is now just:

Type: list of device specifications

We're also heading for more consistency, speaking about "device
specification" or shortly "devspec". Say if we have something like
"storage.foo.bar", "foo.bar" is the "device specification" and "foo" is
the "device specification type" and "bar" is the "device specification
name".

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 8e861d2eeb99d86096efa6b0e482e69d6e4dfb6a
      
https://github.com/NixOS/nixpkgs/commit/8e861d2eeb99d86096efa6b0e482e69d6e4dfb6a
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-06 (Fri, 06 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/default.nix
    M nixos/modules/tasks/storage/lib.nix

  Log Message:
  -----------
  nixos/storage: Make devspec an attrset internally

So far we passed the device specification as-is to nixpart, but from
within the module system it's quite tricky to validate or look up such a
string, because we need to parse it every time we need to do a look up
an a configuration value in "storage.*".

Now a device specification is an attribute set consisting of a `name'
and a `type' attribute. We also have a new applyTypeContainer attribute
we need to pass to mkDeviceSpecOption so that we can properly convert
things such as "listOf devspecType" into a list of valid internal
representations of device specifications.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 2b0095599c649433d1d80e42c5a540af53c0df50
      
https://github.com/NixOS/nixpkgs/commit/2b0095599c649433d1d80e42c5a540af53c0df50
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-06 (Fri, 06 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/lib.nix

  Log Message:
  -----------
  nixos/storage/lib: Propagate devspec's config

This is handy if we want to look up configuration options for a specific
device specification, so with only the internal representation of a
devspec we can simply say devspec.uuid to get a generated UUID.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: a8952b1ae4c282808925bb6054c991edf38186d0
      
https://github.com/NixOS/nixpkgs/commit/a8952b1ae4c282808925bb6054c991edf38186d0
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-06 (Fri, 06 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/default.nix

  Log Message:
  -----------
  nixos/storage: Integrate storage UUIDs in fs/swaps

This implements the deterministically generated UUIDs to be used while
mounting file systems, but only if there is no label set already. So the
user still has a way to set labels (which are also applied by nixpart)
and use them accordingly, even though the UUIDs should be more
distincive.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: c97a18a64a193167adb1021005b61fb02fa282d5
      
https://github.com/NixOS/nixpkgs/commit/c97a18a64a193167adb1021005b61fb02fa282d5
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M nixos/modules/tasks/storage/default.nix
    M nixos/modules/tasks/storage/lib.nix

  Log Message:
  -----------
  nixos/storage: Don't put whole config in devspec

While it may be handy to put the whole configuration of the
corresponding device specification into the values of the options
referring to them, this unfortunately blows up the size of the JSON
output we pass to nixpart.

This is unnecessary because we're only interested in the UUID.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 3ed76021f868365d3acaed73854cd3a857a4983a
      
https://github.com/NixOS/nixpkgs/commit/3ed76021f868365d3acaed73854cd3a857a4983a
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M pkgs/development/python-modules/blivet/default.nix
    A pkgs/development/python-modules/blivet/uuids.patch

  Log Message:
  -----------
  blivet: Add patch for setting UUIDs

I'm heading for a hybrid approach (using UUIDs and partition layout
holes) in nixpart for achieving storage tree determinism, so we need to
have support for setting UUIDs. Blivet currently doesn't yet support
this, so I've implemented it.

Upstream pull request:

https://github.com/rhinstaller/blivet/pull/537

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 135f831370f19a545176af271f85c42e24bbfd0b
      
https://github.com/NixOS/nixpkgs/commit/135f831370f19a545176af271f85c42e24bbfd0b
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M nixos/tests/blivet.nix

  Log Message:
  -----------
  nixos/tests/blivet: Add mtools and ntfs3g

These tools are needed in order to run tests for NTFS and for setting
the serial of a FAT file system after it has been created.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: e2a24488b93f7e70081b852074c19ad33006c07a
      
https://github.com/NixOS/nixpkgs/commit/e2a24488b93f7e70081b852074c19ad33006c07a
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M pkgs/development/python-modules/blivet/default.nix
    A pkgs/development/python-modules/blivet/ntfs-formattable.patch

  Log Message:
  -----------
  blivet: Add patch to set NTFS formattable

Even though the ntfs3g utilities are available inside our test
environment, the format didn't get advertised as formattable because the
_formattable attribute wasn't set to True.

Submitted upstream at:

https://github.com/rhinstaller/blivet/pull/536

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 74a45d7142c36ee5e8c39e35aca0cff75c750e19
      
https://github.com/NixOS/nixpkgs/commit/74a45d7142c36ee5e8c39e35aca0cff75c750e19
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M pkgs/tools/filesystems/nixpart/default.nix

  Log Message:
  -----------
  nixpart: Update to latest master version

Switches to using a dictionary for devspecs and supports setting UUIDs
for every device specification (currently only sets RFC4122-style
UUIDs).

Signed-off-by: aszlig <asz...@redmoonstudios.org>


  Commit: 528c6ac8eac74abe0fe7a5798608344408118bee
      
https://github.com/NixOS/nixpkgs/commit/528c6ac8eac74abe0fe7a5798608344408118bee
  Author: aszlig <asz...@redmoonstudios.org>
  Date:   2017-01-15 (Sun, 15 Jan 2017)

  Changed paths:
    M nixos/tests/storage.nix

  Log Message:
  -----------
  nixos/tests/storage/matchers: Remove labels

We no longer need to use labels now that every file system gets assigned
an UUID in latest nixpart.

Signed-off-by: aszlig <asz...@redmoonstudios.org>


Compare: https://github.com/NixOS/nixpkgs/compare/c0c04ca1d380...528c6ac8eac7
_______________________________________________
nix-commits mailing list
nix-comm...@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-commits

Reply via email to