Disable gitea own ssh server startup

This commit is contained in:
Evie Litherland-Smith 2023-05-26 14:30:42 +01:00
parent 0503c681c2
commit 341f392e40
3 changed files with 7 additions and 17 deletions

View file

@ -9,12 +9,10 @@
./services/Vanguard.nix
];
networking.hostName = "Vanguard"; # Define your hostname.
#networking.wireless.networks."LAN LAN Ranch".pskRaw = "d4c31e976456783b61d573ee49c94f93914a81bf1048c2f2e1e166c36bdfcd4a";
networking.nameservers = ["192.168.1.166" "9.9.9.9"];
networking.firewall = {
enable = true;
allowedTCPPorts = [22];
networking = {
hostName = "Vanguard"; # Define your hostname.
nameservers = ["192.168.1.166" "9.9.9.9"];
firewall = {enable = true;};
};
users.users.xenia = {

View file

@ -6,10 +6,8 @@
server = {
ROOT_URL = "https://git.xenia.me.uk";
DOMAIN = "git.xenia.me.uk";
START_SSH_SERVER = true;
SSH_DOMAIN = "git.xenia.me.uk";
SSH_PORT = 2222;
SSH_LISTEN_PORT = 30922;
};
service.DISABLE_REGISTRATION = true;
ui = {

View file

@ -1,5 +1,5 @@
{...}: {
imports = [./default.nix];
imports = [./default.nix ./sshd.nix];
services.traefik.dynamicConfigOptions = {
http = {
routers.gitea = {
@ -13,16 +13,10 @@
tcp = {
routers.gitea-ssh = {
rule = "HostSNI(`git.xenia.me.uk`)";
entryPoints = ["ssh"];
service = "gitea-sshservice";
entryPoints = ["ssh" "https"];
service = "ssh-redirect";
tls = {certResolver = "default";};
};
routers.gitea-ssh-local = {
rule = "ClientIP(`192.168.0.0/16`)";
entryPoints = ["ssh"];
service = "gitea-sshservice";
};
services.gitea-sshservice.loadBalancer.servers = [{address = "localhost:30922";}];
};
};
}