@@ -22,10 +22,13 @@ Conservatively, a x86_64 machine with:
2222
2323## Setup
2424
25- ** If you're just testing this out, you can use the
25+ ### Installing Guix
26+
27+ If you're just testing this out, you can use the
2628[ Dockerfile] [ fanquake/guix-docker ] for convenience. It automatically speeds up
2729your builds by [ using substitutes] ( #speeding-up-builds-with-substitute-servers ) .
28- Should you choose to use the Dockerfile, you can skip this section.**
30+ If you don't want this behaviour, refer to the [ next
31+ section] ( #choosing-your-security-model ) .
2932
3033Otherwise, follow the [ Guix installation guide] [ guix/bin-install ] .
3134
@@ -34,10 +37,32 @@ Otherwise, follow the [Guix installation guide][guix/bin-install].
3437> manager/existing setup. It _ only_ touches ` /var/guix ` , ` /gnu ` , and
3538> ` ~/.config/guix ` .
3639
40+ ### Choosing your security model
41+
42+ Guix allows us to achieve better binary security by using our CPU time to build
43+ everything from scratch. However, it doesn't sacrifice user choice in pursuit of
44+ this: users can decide whether or not to bootstrap and to use substitutes.
45+
3746After installation, you may want to consider [ adding substitute
3847servers] ( #speeding-up-builds-with-substitute-servers ) to speed up your build if
39- that fits your security model. (skippable if you're using the
40- [ Dockerfile] [ fanquake/guix-docker ] )
48+ that fits your security model (say, if you're just testing that this works).
49+ This is skippable if you're using the [ Dockerfile] [ fanquake/guix-docker ] .
50+
51+ If you prefer not to use any substitutes, make sure to set
52+ ` ADDITIONAL_GUIX_ENVIRONMENT_FLAGS ` like the following snippet. The first build
53+ will take a while, but the resulting packages will be cached for future builds.
54+
55+ ``` sh
56+ export ADDITIONAL_GUIX_ENVIRONMENT_FLAGS=' --no-substitutes'
57+ ```
58+
59+ Likewise, to perform a bootstrapped build (takes even longer):
60+
61+ ``` sh
62+ export ADDITIONAL_GUIX_ENVIRONMENT_FLAGS=' --bootstrap --no-substitutes'
63+ ```
64+
65+ ### Using the right Guix
4166
4267Once Guix is installed, deploy our patched version into your current Guix
4368profile. The changes there are slowly being upstreamed.
@@ -55,7 +80,7 @@ at the end of the `guix pull`)
5580export PATH=" ${HOME} /.config/guix/current/bin${PATH: +: } $PATH "
5681```
5782
58- > Note: There is ongoing work to eliminate this ` guix pull ` step using Guix
83+ > Note: There is ongoing work to eliminate this entire section using Guix
5984> [ inferiors] [ guix/inferiors ] and [ channels] [ guix/channels ] .
6085
6186## Usage
@@ -123,7 +148,8 @@ find output/ -type f -print0 | sort -z | xargs -r0 sha256sum
123148* _ ** ADDITIONAL_GUIX_ENVIRONMENT_FLAGS** _
124149
125150 Additional flags to be passed to ` guix environment ` . For a fully-bootstrapped
126- build, set this to ` --bootstrap --no-substitutes ` . Note that a
151+ build, set this to ` --bootstrap --no-substitutes ` (refer to the [ security
152+ model section] ( #choosing-your-security-model ) for more details). Note that a
127153 fully-bootstrapped build will take quite a long time on the first run.
128154
129155## Tips and Tricks
0 commit comments