Flakeify the docker image

This commit is contained in:
Paul Brinkmeier 2023-04-03 14:11:01 +02:00
parent 1a2d9edc99
commit bff14baa1f
3 changed files with 18 additions and 15 deletions

View File

@ -6,24 +6,29 @@
$ nix build
```
## Running
```
$ nix run
```
## Building the Docker image
```
# TODO
$ docker load < $(nix-build nix/docker-image.nix)
$ docker load < $(nix build .#docker --print-out-paths)
```
## Development Shell
Includes Stack, `haskell-language-server`, `gen-hie` etc.
Includes Stack, GHC, `haskell-language-server`, `gen-hie` etc.
```
nix develop
$ nix develop
```
## Running Stack and GHC
```
nix run .#stack
nix run .#ghc
$ nix run .#stack
$ nix run .#ghc
```

View File

@ -57,6 +57,13 @@
inherit stack;
inherit utoy;
docker =
pkgs.dockerTools.buildImage {
name = "git.pbrinkmeier.de/paul/utoy";
tag = utoy.version;
config.Cmd = [ "${utoy}/bin/utoy" ];
};
default = utoy;
};

View File

@ -1,9 +0,0 @@
let
pkgs = import ./pkgs.nix {};
utoy = import ../utoy.nix;
in
pkgs.dockerTools.buildImage {
name = "git.pbrinkmeier.de/paul/utoy";
tag = utoy.version;
config.Cmd = [ "${utoy}/bin/utoy" ];
}