nixos/modules/code-server/default.nix

21 lines
344 B
Nix
Raw Normal View History

2022-01-22 07:15:47 +01:00
{ self, pkgs, ... }:
2022-01-03 14:18:55 +01:00
let
2022-01-22 07:15:47 +01:00
username = import "${self}/username.nix";
2022-01-03 14:18:55 +01:00
in
{
services.code-server = {
enable = true;
user = username;
2022-01-03 14:36:14 +01:00
host = "0.0.0.0";
2022-01-03 14:38:29 +01:00
auth = "none";
2022-01-03 15:16:47 +01:00
extraPackages = with pkgs;
[
2022-01-03 15:58:32 +01:00
python3
2022-01-03 15:16:47 +01:00
# other
2022-01-03 15:28:05 +01:00
bash
2022-01-03 15:16:47 +01:00
git
2022-01-03 15:21:43 +01:00
];
2022-01-03 14:18:55 +01:00
};
2022-01-03 14:32:00 +01:00
networking.firewall.allowedTCPPorts = [ 4444 ];
2022-01-03 14:18:55 +01:00
}