diff --git a/nix-files/conf.nix b/dev/nix/conf.nix similarity index 100% rename from nix-files/conf.nix rename to dev/nix/conf.nix diff --git a/nix-files/flake.lock b/dev/nix/flake.lock similarity index 100% rename from nix-files/flake.lock rename to dev/nix/flake.lock diff --git a/nix-files/flake.nix b/dev/nix/flake.nix similarity index 91% rename from nix-files/flake.nix rename to dev/nix/flake.nix index 6988d54f114d..3e67b4484a41 100644 --- a/nix-files/flake.nix +++ b/dev/nix/flake.nix @@ -1,3 +1,5 @@ +# NOTE: all dependencies changed here must also be changed in the Makefile. + { inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-22.11"; @@ -35,7 +37,7 @@ inherit nodeEnv; }; pythonPkgs = pkgs.python310Packages; - mkdocs = with pythonPkgs; + mkdocs = with pythonPkgs; # upgrade this in the Makefile if upgraded here buildPythonPackage rec { pname = "mkdocs"; version = "1.2.4"; @@ -57,7 +59,7 @@ ]; doCheck = false; }; - mkdocs-material-extensions = with pythonPkgs; + mkdocs-material-extensions = with pythonPkgs; # upgrade this in the Makefile if upgraded here buildPythonPackage rec { pname = "mkdocs_material_extensions"; version = "1.1.1"; @@ -68,7 +70,7 @@ buildInputs = [ hatchling babel ]; format = "pyproject"; }; - mkdocs-material = with pythonPkgs; + mkdocs-material = with pythonPkgs; # upgrade this in the Makefile if upgraded here buildPythonPackage rec { pname = "mkdocs-material"; version = "8.1.9"; @@ -110,7 +112,7 @@ propagatedBuildInputs = [ editdistpy ]; format = "pyproject"; }; - mkdocs-spellcheck = with pythonPkgs; + mkdocs-spellcheck = with pythonPkgs; # upgrade this in the Makefile if upgraded here buildPythonPackage rec { pname = "mkdocs-spellcheck"; version = "0.2.1"; @@ -162,9 +164,9 @@ doCheck = false; }; - mockery = pkgs.buildGoModule rec { + mockery = pkgs.buildGoModule rec { pname = "mockery"; - version = "2.10.0"; + version = "2.10.0"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "vektra"; @@ -178,7 +180,7 @@ protoc-gen-gogo-all = pkgs.buildGoModule rec { pname = "protoc-gen-gogo"; - version = "1.3.2"; + version = "1.3.2"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "gogo"; @@ -191,7 +193,7 @@ }; grpc-ecosystem = pkgs.buildGoModule rec { pname = "grpc-ecosystem"; - version = "1.16.0"; + version = "1.16.0"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "grpc-ecosystem"; @@ -205,7 +207,7 @@ go-swagger = pkgs.buildGoModule rec { pname = "go-swagger"; - version = "0.28.0"; + version = "0.28.0"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "go-swagger"; @@ -219,7 +221,7 @@ controller-tools = pkgs.buildGoModule rec { pname = "controller-tools"; - version = "0.4.1"; + version = "0.4.1"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "kubernetes-sigs"; @@ -233,7 +235,7 @@ k8sio-tools = pkgs.buildGoModule rec { pname = "k8sio-tools"; - version = "0.21.5"; + version = "0.21.5"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "kubernetes"; @@ -247,7 +249,7 @@ goreman = pkgs.buildGoModule rec { pname = "goreman"; - version = "0.3.11"; + version = "0.3.11"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "mattn"; repo = "goreman"; @@ -260,7 +262,7 @@ stern = pkgs.buildGoModule rec { pname = "stern"; - version = "1.25.0"; + version = "1.25.0"; # upgrade this in the Makefile if upgraded here src = pkgs.fetchFromGitHub { owner = "stern"; repo = "stern"; diff --git a/nix-files/node-env.nix b/dev/nix/node-env.nix similarity index 100% rename from nix-files/node-env.nix rename to dev/nix/node-env.nix diff --git a/nix-files/node-packages.nix b/dev/nix/node-packages.nix similarity index 100% rename from nix-files/node-packages.nix rename to dev/nix/node-packages.nix diff --git a/nix-files/package.json b/dev/nix/package.json similarity index 100% rename from nix-files/package.json rename to dev/nix/package.json diff --git a/docs/running-nix.md b/docs/running-nix.md index 2279d1bf9e9d..d9a4af73070b 100644 --- a/docs/running-nix.md +++ b/docs/running-nix.md @@ -7,7 +7,7 @@ Here are the steps to follow: 1. Modify the hosts file according to [this](https://argoproj.github.io/argo-workflows/running-locally/), don't worry about the other instructions. 2. Set up a kubernetes cluster, k3d is the recommended solution here. 3. Install [Nix](https://nixos.org/download.html). - 4. Run "nix develop --extra-experimental-features nix-command --extra-experimental-features flakes ./nix-files/ --impure" (you can add the extra features as a default in your nix.conf file). + 4. Run "nix develop --extra-experimental-features nix-command --extra-experimental-features flakes ./dev/nix/ --impure" (you can add the extra features as a default in your nix.conf file). 5. Run "devenv up". ## Warning @@ -31,3 +31,9 @@ and replace the existing hash value. The almost exact same principles apply here, the only difference being you must change the `vendorHash` and the `sha256` fields. The `vendorHash` is a hash of the vendored dependencies while the `sha256` is for the sources fetched from the `fetchFromGithub` call. + +### Why am I getting a vendorSha256 mismatch ? +Unfortunately, dependabot is not capable of upgrading flakes automatically, when the go modules are automatically upgraded the +hash of the vendor dependencies changes but this change isn't automatically reflected in the nix file. The `vendorSha256` field that needs to +be upgraded can be found by searching for `${package.name} = pkgs.buildGoModule` in the nix file. + diff --git a/nix-files/.gitignore b/nix-files/.gitignore deleted file mode 100644 index f4baf22ce2f1..000000000000 --- a/nix-files/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -result/ -yarn.lock