feat: add global ssh key configuration
This commit is contained in:
parent
def062a84c
commit
5c67309439
16 changed files with 236 additions and 254 deletions
|
|
@ -29,7 +29,7 @@ in
|
|||
privateNetwork = true;
|
||||
hostBridge = "server";
|
||||
hostAddress = "${networkPrefix}.97.1";
|
||||
localAddress = "${networkPrefix}.97.55/24"; # Different from gitea's .50
|
||||
localAddress = "${networkPrefix}.97.55/24"; # Different from gitea's .50
|
||||
bindMounts = {
|
||||
"/var/lib/forgejo" = {
|
||||
hostPath = "/var/lib/forgejo/";
|
||||
|
|
@ -50,7 +50,7 @@ in
|
|||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
vim # my preferred editor
|
||||
vim # my preferred editor
|
||||
];
|
||||
|
||||
networking = {
|
||||
|
|
@ -96,29 +96,29 @@ in
|
|||
openid = {
|
||||
ENABLE_OPENID_SIGNIN = false;
|
||||
ENABLE_OPENID_SIGNUP = true;
|
||||
WHITELISTED_URIS = "auth.cloonar.com";
|
||||
WHITELISTED_URIS = "auth.cloonar.com";
|
||||
};
|
||||
service = {
|
||||
DISABLE_REGISTRATION = false;
|
||||
ALLOW_ONLY_EXTERNAL_REGISTRATION = true;
|
||||
SHOW_REGISTRATION_BUTTON = false;
|
||||
ENABLE_NOTIFY_MAIL = true;
|
||||
REQUIRE_SIGNIN_VIEW = false;
|
||||
DISABLE_REGISTRATION = false;
|
||||
ALLOW_ONLY_EXTERNAL_REGISTRATION = true;
|
||||
SHOW_REGISTRATION_BUTTON = false;
|
||||
ENABLE_NOTIFY_MAIL = true;
|
||||
REQUIRE_SIGNIN_VIEW = false;
|
||||
};
|
||||
mailer = {
|
||||
ENABLED = true;
|
||||
FROM = "Forgejo Cloonar <gitea@cloonar.com>";
|
||||
PROTOCOL = "smtp+starttls";
|
||||
SMTP_ADDR = "mail.cloonar.com";
|
||||
SMTP_PORT = 587;
|
||||
USER = "gitea@cloonar.com";
|
||||
ENABLED = true;
|
||||
FROM = "Forgejo Cloonar <gitea@cloonar.com>";
|
||||
PROTOCOL = "smtp+starttls";
|
||||
SMTP_ADDR = "mail.cloonar.com";
|
||||
SMTP_PORT = 587;
|
||||
USER = "gitea@cloonar.com";
|
||||
};
|
||||
actions = {
|
||||
ENABLED = true;
|
||||
DEFAULT_ACTIONS_URL = "github"; # Pull actions from GitHub
|
||||
DEFAULT_ACTIONS_URL = "github"; # Pull actions from GitHub
|
||||
};
|
||||
attachment = {
|
||||
MAX_SIZE = 2048; # 2GB in MB for general attachments
|
||||
MAX_SIZE = 2048; # 2GB in MB for general attachments
|
||||
};
|
||||
packages = {
|
||||
ENABLED = true;
|
||||
|
|
@ -130,10 +130,7 @@ in
|
|||
systemd.services.forgejo.serviceConfig.EnvironmentFile = "/run/secrets/forgejo-mailer-password";
|
||||
|
||||
services.openssh.enable = true;
|
||||
users.users.root.openssh.authorizedKeys.keys = [
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDN/2SAFm50kraB1fepAizox/QRXxB7WbqVbH+5OPalDT47VIJGNKOKhixQoqhABHxEoLxdf/C83wxlCVlPV9poLfDgVkA3Lyt5r3tSFQ6QjjOJAgchWamMsxxyGBedhKvhiEzcr/Lxytnoz3kjDG8fqQJwEpdqMmJoMUfyL2Rqp16u+FQ7d5aJtwO8EUqovhMaNO7rggjPpV/uMOg+tBxxmscliN7DLuP4EMTA/FwXVzcFNbOx3K9BdpMRAaSJt4SWcJO2cS2KHA5n/H+PQI7nz5KN3Yr/upJN5fROhi/SHvK39QOx12Pv7FCuWlc+oR68vLaoCKYhnkl3DnCfc7A7"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIRQuPqH5fdX3KEw7DXzWEdO3AlUn1oSmtJtHB71ICoH Generated By Termius"
|
||||
];
|
||||
users.users.root.openssh.authorizedKeys.keys = import ../utils/ssh-keys.nix;
|
||||
|
||||
users.users.forgejo = user;
|
||||
users.groups.forgejo = group;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue