From 4edadb0888a34845f9d7b5fbfe0047638e52d2cf Mon Sep 17 00:00:00 2001 From: seth Date: Tue, 14 Mar 2023 20:38:51 -0400 Subject: add docker container --- flake.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index 7ec30ab..698fc32 100644 --- a/flake.nix +++ b/flake.nix @@ -6,6 +6,9 @@ pre-commit-hooks = { url = "github:cachix/pre-commit-hooks.nix"; inputs.nixpkgs.follows = "nixpkgs"; + inputs.nixpkgs-stable.follows = "nixpkgs"; + inputs.flake-compat.follows = "flake-compat"; + inputs.flake-utils.follows = "flake-utils"; }; flake-compat = { url = "github:edolstra/flake-compat"; @@ -18,8 +21,8 @@ self, nixpkgs, pre-commit-hooks, - flake-compat, flake-utils, + ... }: let version = "0.0.1"; supportedSystems = with flake-utils.lib.system; [x86_64-linux x86_64-darwin aarch64-linux aarch64-darwin]; @@ -37,6 +40,12 @@ format = "flit"; propagatedBuildInputs = with pkgs.python39Packages; [hatchling discordpy requests]; }; + container = with pkgs.dockerTools; + buildImage { + name = "teawiebot"; + copyToRoot = [caCertificates]; + config.Cmd = ["${self.packages.${system}.teawiebot}/bin/teawiebot"]; + }; } // {default = self.packages.${system}.teawiebot;}; -- cgit v1.2.3