update README
This commit is contained in:
parent
0b45b20d8a
commit
509ebbae5a
63
README.md
63
README.md
|
@ -6,19 +6,8 @@ Currently the overlay provides these packages:
|
||||||
- GNUnet itself
|
- GNUnet itself
|
||||||
- libgnurl
|
- libgnurl
|
||||||
|
|
||||||
## Installation
|
## Installation of the GNUnet service (NixOS)
|
||||||
We can install the overlay into the user environment like this:
|
On NixOS we can install this overlay system-wide and then enable the GNUnet service. This will install the *multi-user setup* as described in the [official documentation](https://docs.gnunet.org/handbook/gnunet.html#Installing-GNUnet). We have to add this to our ``/etc/nixos/configuration.nix``:
|
||||||
|
|
||||||
```shell
|
|
||||||
$ ln -s ~/.config/nixpkgs/overlays/gnunet-overlay.nix gnunet-overlay
|
|
||||||
```
|
|
||||||
Now we can install the packages using
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ nix-env -f '<nixpkgs>' -iA gnunet
|
|
||||||
```
|
|
||||||
|
|
||||||
To use the packages from the overlay system-wide (on NixOS) we can add this to our ``/etc/nixos/configuration.nix``:
|
|
||||||
|
|
||||||
```
|
```
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
@ -29,10 +18,50 @@ To use the packages from the overlay system-wide (on NixOS) we can add this to o
|
||||||
(import (fetchGit https://ulrich.earth/code/nixpkgs-gnunet))
|
(import (fetchGit https://ulrich.earth/code/nixpkgs-gnunet))
|
||||||
];
|
];
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
services.gnunet = {
|
||||||
...
|
enable = true;
|
||||||
gnunet
|
};
|
||||||
];
|
|
||||||
...
|
...
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
We can add options to the global GNUnet configuration file like this:
|
||||||
|
|
||||||
|
```
|
||||||
|
services.gnunet = {
|
||||||
|
enable = true;
|
||||||
|
extraOptions = ''
|
||||||
|
[NAT]
|
||||||
|
ENABLE_UPNP = NO
|
||||||
|
|
||||||
|
[FS]
|
||||||
|
IMMEDIATE_START = NO
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
|
After running ``nixos-rebuild switch`` the GNUnet system services should be running (we still have to [start GNUnet per user](https://docs.gnunet.org/handbook/gnunet.html#Starting-GNUnet):
|
||||||
|
|
||||||
|
```
|
||||||
|
$ touch ~/.config/gnunet.conf
|
||||||
|
$ gnunet-arm -s
|
||||||
|
```
|
||||||
|
|
||||||
|
## Installation of the GNUnet package (Nix on other systems)
|
||||||
|
We can install the overlay into the user environment like this:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
$ ln -s ~/.config/nixpkgs/overlays/gnunet-overlay.nix gnunet-overlay
|
||||||
|
```
|
||||||
|
Now we can install the GNUnet package for our user. This will allow a *single-user setup* as described in the [official documentation](https://docs.gnunet.org/handbook/gnunet.html#Installing-GNUnet).
|
||||||
|
|
||||||
|
```shell
|
||||||
|
$ nix-env -f '<nixpkgs>' -iA gnunet
|
||||||
|
```
|
||||||
|
|
||||||
|
Now we can [start GNUnet](https://docs.gnunet.org/handbook/gnunet.html#Starting-GNUnet):
|
||||||
|
|
||||||
|
```
|
||||||
|
$ touch ~/.config/gnuent.conf
|
||||||
|
$ gnuent-arm -s
|
||||||
|
```
|
||||||
|
|
Loading…
Reference in New Issue