[m] Server: adding docker
This commit is contained in:
parent
c0d7023d90
commit
7a3a2a9f69
@ -26,8 +26,8 @@
|
||||
padding = "12";
|
||||
horizontal_padding = "15";
|
||||
text_icon_padding = "0";
|
||||
frame_width = "2";
|
||||
frame_color = "#${config.colorScheme.colors.base03}";
|
||||
frame_width = "${config.colorScheme.colors.border-width}";
|
||||
frame_color = "#${config.colorScheme.colors.base04}";
|
||||
separator_color = "auto";
|
||||
sort = "yes";
|
||||
font = "IBM Plex Mono 14";
|
||||
@ -69,23 +69,23 @@
|
||||
|
||||
};
|
||||
urgency_low = {
|
||||
background = "#${config.colorScheme.colors.base00}";
|
||||
background = "#${config.colorScheme.colors.base01}";
|
||||
foreground = "#${config.colorScheme.colors.base07}";
|
||||
frame_color = "#${config.colorScheme.colors.base03}";
|
||||
timeout = "3";
|
||||
highlight = "#${config.colorScheme.colors.base0B}";
|
||||
};
|
||||
urgency_normal = {
|
||||
background = "#${config.colorScheme.colors.base00}";
|
||||
background = "#${config.colorScheme.colors.base01}";
|
||||
foreground = "#${config.colorScheme.colors.base07}";
|
||||
frame_color = "#${config.colorScheme.colors.base03}";
|
||||
frame_color = "#${config.colorScheme.colors.base04}";
|
||||
timeout = "5";
|
||||
highlight = "#${config.colorScheme.colors.base0C}";
|
||||
};
|
||||
urgency_critical = {
|
||||
background = "#${config.colorScheme.colors.base00}";
|
||||
background = "#${config.colorScheme.colors.base01}";
|
||||
foreground = "#${config.colorScheme.colors.base0F}";
|
||||
frame_color = "#${config.colorScheme.colors.base03}";
|
||||
frame_color = "#${config.colorScheme.colors.base0F}";
|
||||
timeout = "10";
|
||||
highlight = "#${config.colorScheme.colors.base0E}";
|
||||
};
|
||||
|
@ -1,6 +1,4 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
{ config, pkgs, ... }: {
|
||||
imports = [ ];
|
||||
|
||||
users.users.sora = {
|
||||
|
@ -1,6 +1,4 @@
|
||||
{ ... }: {
|
||||
imports = [ ./display.nix ];
|
||||
|
||||
config.homecfg = {
|
||||
username = "sora";
|
||||
make = {
|
||||
|
4
systems/avalon/server/default.nix
Normal file
4
systems/avalon/server/default.nix
Normal file
@ -0,0 +1,4 @@
|
||||
{ ... }:
|
||||
{
|
||||
|
||||
}
|
106
systems/avalon/server/docker/default.nix
Normal file
106
systems/avalon/server/docker/default.nix
Normal file
@ -0,0 +1,106 @@
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
HOST_DOMAIN = "helcel.net";
|
||||
MAIL_HOST_DOMAIN = "norereply.${HOST_DOMAIN}";
|
||||
MAIL_SERVER_DOMAIN = "mail.infomaniak.com";
|
||||
in {
|
||||
project.name = "Authentik";
|
||||
|
||||
networks = {
|
||||
internal = {
|
||||
internal = true;
|
||||
external = false;
|
||||
};
|
||||
external = { external = true; };
|
||||
};
|
||||
|
||||
services = {
|
||||
|
||||
auth_postgresql.service = {
|
||||
image = "postgres:14-alpine";
|
||||
container_name = "auth_postgresql";
|
||||
restart = "unless-stopped";
|
||||
networks = [ "internal" ];
|
||||
volumes = [ ];
|
||||
environment = {
|
||||
POSTGRES_PASSWORD = "/run/secrets/AUTHENTIK_POSTGRESQL__PASSWORD";
|
||||
POSTGRES_USER = "authentik";
|
||||
POSTGRES_DB = "authentik";
|
||||
};
|
||||
};
|
||||
|
||||
auth_redis.service = {
|
||||
image = "redis:alpine";
|
||||
container_name = "auth_redis";
|
||||
restart = "unless-stopped";
|
||||
networks = [ "internal" ];
|
||||
volumes = [ ];
|
||||
environment = { };
|
||||
labels = { "traefik.enable" = "false"; };
|
||||
};
|
||||
|
||||
auth_server.service = {
|
||||
image = "ghcr.io/goauthentik/server:latest";
|
||||
container_name = "auth_server";
|
||||
restart = "unless-stopped";
|
||||
networks = [ "internal" "external" ];
|
||||
volumes = [
|
||||
"/media/data/authentik/media:/media"
|
||||
"/media/data/authentik/templates:/templates"
|
||||
];
|
||||
environment = {
|
||||
"AUTHENTIK_REDIS__HOST" = "auth_redis";
|
||||
"AUTHENTIK_POSTGRESQL__HOST" = "auth_postgresql";
|
||||
"AUTHENTIK_POSTGRESQL__USER" = "authentik";
|
||||
"AUTHENTIK_POSTGRESQL__NAME" = "authentik";
|
||||
"AUTHENTIK_POSTGRESQL__PASSWORD" =
|
||||
"/run/secrets/AUTHENTIK_POSTGRESQL__PASSWORD";
|
||||
"AUTHENTIK_SECRET_KEY" = "/run/secrets/AUTHENTIK_SECRET_KEY";
|
||||
"AUTHENTIK_EMAIL__HOST" = "${MAIL_SERVER_DOMAIN}";
|
||||
"AUTHENTIK_EMAIL__PORT" = "587";
|
||||
"AUTHENTIK_EMAIL__USERNAME" = "noreply@${MAIL_HOST_DOMAIN}";
|
||||
"AUTHENTIK_EMAIL__PASSWORD" = "/run/secrets/AUTHENTIK_EMAIL__PASSWORD";
|
||||
"AUTHENTIK_EMAIL__USE_TLS" = "true";
|
||||
"AUTHENTIK_EMAIL__USE_SSL" = "false";
|
||||
"AUTHENTIK_EMAIL__TIMEOUT" = "10";
|
||||
"AUTHENTIK_EMAIL__FROM" = "sso@noreply.${MAIL_HOST_DOMAIN}";
|
||||
};
|
||||
labels = {
|
||||
"traefik.enable" = "true";
|
||||
"traefik.http.routers.sso.entrypoints" = "web-secure";
|
||||
"traefik.http.routers.sso.rule" = "Host(`sso.${HOST_DOMAIN}`)";
|
||||
"traefik.http.routers.sso.tls" = "true";
|
||||
"traefik.http.services.sso.loadbalancer.server.port" = "9000";
|
||||
"traefik.docker.network" = "external";
|
||||
};
|
||||
command = "server";
|
||||
service.ports = [
|
||||
"9999:9000" # host:container
|
||||
];
|
||||
};
|
||||
|
||||
auth_worker.service = {
|
||||
image = "ghcr.io/goauthentik/server:latest";
|
||||
container_name = "auth_worker";
|
||||
restart = "unless-stopped";
|
||||
networks = [ "internal" ];
|
||||
volumes = [
|
||||
"/media/data/authentik/media:/media"
|
||||
"/media/data/authentik/templates:/templates"
|
||||
"/var/run/docker.sock:/var/run/docker.sock"
|
||||
];
|
||||
environment = {
|
||||
"AUTHENTIK_REDIS__HOST" = "auth_redis";
|
||||
"AUTHENTIK_POSTGRESQL__HOST" = "auth_postgresql";
|
||||
"AUTHENTIK_POSTGRESQL__USER" = "authentik";
|
||||
"AUTHENTIK_POSTGRESQL__NAME" = "authentik";
|
||||
"AUTHENTIK_POSTGRESQL__PASSWORD" =
|
||||
"/run/secrets/AUTHENTIK_POSTGRESQL__PASSWORD";
|
||||
"AUTHENTIK_SECRET_KEY" = "/run/secrets/AUTHENTIK_SECRET_KEY";
|
||||
};
|
||||
labels = { "traefik.enable" = "false"; };
|
||||
command = "worker";
|
||||
user = "root";
|
||||
};
|
||||
};
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user