Commit graph

189 commits

Author SHA1 Message Date
Robert Hensing b6bec17eb9 testers.hasPkgConfigModule: Extract and add tests, docs 2023-01-30 00:35:34 +01:00
Matthew Kenigsberg 2334404fb0 fix: doc typo 2023-01-26 16:45:59 -07:00
Naïm Favier 4580a6608d
doc: fix broken links 2023-01-24 13:27:27 +01:00
Gabriella Gonzalez 6d89aa8f1d
darwin.builder: auto-login as the builder user (#208772)
… as suggested by @NiklasGollenstede in:

https://github.com/NixOS/nixpkgs/pull/206951#issuecomment-1369020601

This simplifies the user experience for logging into and
debugging the machine and also simplifies the instructions for
shutting down the machine gracefully.
2023-01-03 21:12:56 -08:00
Winter 15013b3054
darwin.builder: prefer shutting down over halting VM (#208450)
This is preferable because it prevents things like disk corruption (requiring the user to delete the disk image when starting up) that I consistently ran into.
2023-01-02 07:36:41 -08:00
Naïm Favier 8796411139
Merge pull request #208176 from ncfavier/markdown-no-trailing 2023-01-01 14:15:05 +01:00
Gabriella Gonzalez 930b0dfbc1 darwin.builder: Remove trailing ' from host key
The trailing `'` was included by mistake and is not supposed
to be there:

```ShellSession
$ base64 -w0 /etc/ssh/ssh_host_ed25519_key.pub
c3NoLWVkMjU1MTkgQUFBQUMzTnphQzFsWkRJMU5URTVBQUFBSUpCV2N4Yi9CbGFxdDFhdU90RStGOFFVV3JVb3RpQzVxQkorVXVFV2RWQ2Igcm9vdEBuaXhvcwo=
```

The reason it did not cause issues before is because
Nix ignores everything after the `=`:

3dbf9b5af5/src/libutil/util.cc (L1539-L1540)

… so it's harmless but still worth fixing.
2022-12-29 07:19:16 -06:00
Naïm Favier 22ea90a4d8
.editorconfig: apply trailing whitespace removal
editorconfig-checker -disable-indent-size **/*.md
2022-12-29 01:40:50 +01:00
Naïm Favier d11832fd96
doc,nixos/doc: unescape apostrophes
Leftovers from the CommonMark conversion.
2022-12-27 17:13:47 +01:00
Raito Bezarius 22adcaa449 nixos/lib/make-disk-image: docs, UEFI vars recording, more determinism
- Extensive documentation in NixOS manual
- Deterministic mode that fixes various identifiers relative to disk
  partitions and filesystems in ext4 case
- UEFI variable recording
2022-12-24 19:15:29 +01:00
Gabriella Gonzalez 44c6fdabc2 Add documentation 2022-12-19 17:03:45 -08:00
Christian Kemper f6ae4479ea dockerTools: allowing architecture to be specified
... for buildImage, buildLayeredImage and streamLayeredImage,
adding docs and tests.
2022-12-08 20:29:09 +01:00
Colin Arnott bac379f30a
doc: use sri hash syntax
The nixpkgs manual contains references to both sri hash and explicit
sha256 attributes. This is at best confusing to new users. Since the
final destination is exclusive use of sri hashes, see nixos/rfcs#131,
might as well push new users in that direction gently.

Notable exceptions to sri hash support are builtins.fetchTarball,
cataclysm-dda, coq, dockerTools.pullimage, elixir.override, and
fetchCrate. None, other than builtins.fetchTarball, are fundamentally
incompatible, but all currently accept explicit sha256 attributes as
input. Because adding backwards compatibility is out of scope for this
change, they have been left intact, but migration to sri format has been
made for any using old hash formats.

All hashes have been manually tested to be accurate, and updates were
only made for missing upstream artefacts or bugs.
2022-12-04 06:12:18 +00:00
Silvan Mosberger a566d0842e
Merge pull request #172736 from infinisil/docker-nix-shell 2022-11-26 20:21:59 +01:00
Sandro 3a05360e53
Merge pull request #200082 from panicgh/fetchgit-sparse-checkout 2022-11-21 20:00:56 +01:00
Robert Hensing 29352751cf
Merge pull request #196251 from hercules-ci/testers-build-failure-and-equal-contents
`testers`: Add `testBuildFailure` and `testEqualContents`
2022-11-21 06:17:00 +01:00
Nicolas Benes f6b07f0e2f fetchgit: make sparseCheckout a list of strings
The `sparseCheckout` argument allows the user to specify directories or
patterns of files, which Git uses to filter files it should check-out.

Git expects a multi-line string on stdin ("newline-delimited list", see
`git-sparse-checkout(1)`), but within nixpkgs it is more consistent to
use a list of strings instead. The list elements are joined to a
multi-line string only before passing it to the builder script.

A deprecation warning is emitted if a (multi-line) string is passed to
`sparseCheckout`, but for the time being it is still accepted.
2022-11-15 19:45:33 +01:00
Ryan Mulligan f3d0e1d5c3 nixpkgs/doc: fix admonition syntax
Match admonition syntax in

https://nixos.org/manual/nixpkgs/unstable/#chap-contributing
2022-11-08 07:30:20 -08:00
Robert Hensing e20a362908 testers.testEqualContents: init 2022-10-27 14:06:38 +02:00
Robert Hensing 44d0f37833 testers.testBuildFailure: init 2022-10-27 14:06:38 +02:00
Silvan Mosberger 8ec0837a72 Introduce dockerTools.buildNixShellImage 2022-10-07 22:04:22 +02:00
Дамјан Георгиевски 4e385bec15
add documentation for the pkgs.portableService tool (#193081)
* add documentation for the pkgs.portableService tool

as introduced in 499aebcf34

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-10-07 10:37:56 +02:00
Ivar Scholten 6c40872147
doc/testers: testVersion -> testers.testVersion, add example 2022-09-15 22:46:37 +02:00
Robert Hensing 62b25a28fe
Merge pull request #170906 from Sohalt/dockerTools.ca-certificates.crt
dockerTools ca-certificates.crt helper
2022-08-31 14:08:02 +02:00
Alex James c9af898255
dockerTools.buildImage: make VM memSize configurable
Fixes #186752. This adds buildVMMemorySize (defaults to 512 MiB) to
buildImage, which is passed to vm.runInLinuxVM. This is needed for
larger base images, which may otherwise cause container build failures
due to OOM in the VM.
2022-08-16 21:47:29 -05:00
Winter dbd18a63a7 fetchgit: allow disabling cone mode for sparse checkouts, fix test 2022-08-14 23:03:07 +02:00
Florian Klink 00ff154265
Merge pull request #174093 from NixOS/doc-fakenss
nixos/doc: document fakeNss, binSh
2022-08-04 21:06:19 +07:00
Valentin Gagarin 671ce969a9
Merge pull request #179489 from Thornycrackers-Forks/fetcher-docs-update
doc/builders/fetchers: Add examples, reduce sentence complexity
2022-08-03 11:50:56 +02:00
Cody Hiar 3c2cd351d4 Add example error message. 2022-08-02 11:07:36 -06:00
Cody Hiar 9c292dd02e Updating sha256 to more realistic example 2022-08-02 10:55:15 -06:00
Cody Hiar 0e91d53cc5
Update doc/builders/fetchers.chapter.md
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-08-02 10:52:08 -06:00
Cody Hiar 0685e4a929
Update doc/builders/fetchers.chapter.md
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-08-02 10:51:38 -06:00
Cody Hiar 6d0bf6ae05
Update doc/builders/fetchers.chapter.md
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-08-02 10:51:09 -06:00
Cody Hiar 0444078dab
Update doc/builders/fetchers.chapter.md
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-08-02 10:50:22 -06:00
Cody Hiar 53ffebbe1f
Update doc/builders/fetchers.chapter.md
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2022-08-02 10:50:05 -06:00
Florian Klink 6e254a6c35 nixos/doc: update contents to copyToRoot
contents is deprecated now, use the copyToRoot attribute.
2022-08-01 13:41:41 +07:00
Florian Klink 4393ed8679 Update doc/builders/images/dockertools.section.md
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2022-08-01 13:34:20 +07:00
Florian Klink d84e7842a5 nixos/doc: document fakeNss, binSh 2022-08-01 13:34:20 +07:00
Arnout Engelen 0dd7792b4c
nixpkgs/doc: remove unused unfree.xml
This section was broken out into its own file in efb55d2a42 but
apparently never actually got included anywhere.

Since then a more detailed section on using unfree packages has been
introduced.

Copied the introduction and removed the rest of the file.
2022-07-28 16:54:32 +02:00
Cody Hiar f25dd50085
Update doc/builders/fetchers.chapter.md
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2022-07-18 11:26:51 -06:00
sohalt c9d8e34fc4 dockerTools: document environment helpers 2022-07-07 14:50:23 +02:00
Robert Hensing e007eb480c dockerTools.buildImage: Add copyToRoot to replace contents, explain usage 2022-07-06 07:30:24 +02:00
Cody Hiar 6a9987a095 Updated wording from code review 2022-07-04 14:39:11 -06:00
Cody Hiar 24e95a4461 Remove possessive apostrophes 2022-06-29 12:50:16 -06:00
Cody Hiar 48d5f38c6a doc/builders/fetchers: Add examples, reduce sentence complexity 2022-06-28 17:18:48 -06:00
adisbladis 02c180b646
Merge pull request #176324 from meebey/meebey/meebey-patch-1
doc/builders/images/dockertools: improve shadowSetup example
2022-06-21 20:24:20 +08:00
Mirco Bauer ac66ff97ed doc/builders/images/dockertools: improve shadowSetup example
The example snippet will fail with this error as it is not self contained and
assumes `shadowSetup` was given:

    $ nix-build docker-image.nix
    error: undefined variable 'shadowSetup' at docker-image.nix:20:7

Instead use the full reference to `shadowSetup` in the example so it will work
as stated.
2022-06-05 09:45:58 +08:00
Florian Klink 1cefcfab2d nixos/doc: move fetchpatch documentation to fetcher documentation
… and link from the coding-conventions chapter to it.

Closes #48569.
2022-06-03 14:37:31 +02:00
Klemens Nanni 787a444596 doc: firefox: Show how to use PKCS#11 Proxy Module
`p11-kit-proxy.so` makes it able to use multiple PKCS#11 modules and
manage them through p11-kit(8).

Fix indentation while here.
2022-06-01 01:22:46 +02:00
Robert Hensing e8ffb6a727 doc/testers: Mention nixosTests in nixosTest doc 2022-05-05 13:08:05 +02:00