diff --git a/docker-image.nix b/docker-image.nix new file mode 100644 index 0000000..a443348 --- /dev/null +++ b/docker-image.nix @@ -0,0 +1,41 @@ +{ dockerTools +, cctld +, lib +, +}: +dockerTools.buildLayeredImage { + name = "ghcr.io/cspr-rad/cctl-rs"; + tag = "cctl-casper-node-1.5.7"; + extraCommands = '' + mkdir -p tmp + ''; + config = { + Cmd = lib.getExe cctld; + ExposedPorts = { + # RPC ports + "11101/tcp" = { }; + "11102/tcp" = { }; + "11103/tcp" = { }; + "11104/tcp" = { }; + "11105/tcp" = { }; + # REST ports + "14101/tcp" = { }; + "14102/tcp" = { }; + "14103/tcp" = { }; + "14104/tcp" = { }; + "14105/tcp" = { }; + # SSE ports + "18101/tcp" = { }; + "18102/tcp" = { }; + "18103/tcp" = { }; + "18104/tcp" = { }; + "18105/tcp" = { }; + # Consensus ports + "22101/tcp" = { }; + "22102/tcp" = { }; + "22103/tcp" = { }; + "22104/tcp" = { }; + "22105/tcp" = { }; + }; + }; +} diff --git a/flake.nix b/flake.nix index 76e89c1..743b40e 100644 --- a/flake.nix +++ b/flake.nix @@ -108,6 +108,8 @@ }); default = self'.packages.cctld; + + cctl-docker-image = pkgs.callPackage ./docker-image.nix { inherit (self'.packages) cctld; }; }; checks = {