Fix taiga image uploads
Previously there were 2 problems with taiga image uploads
- The env variables for the domain were set incorrectly
- In the front container, the media and static folders were in the wrong
place
Change-Id: I232c0263cf7b8ea209870fc4d1a98ecd066bc60a
Signed-off-by: Skyler Grey <minion@clicks.codes>
Reviewed-on: https://git.clicks.codes/c/Clicks/NixFiles/+/182
Reviewed-by: Samuel Shuert <coded@clicks.codes>
diff --git a/modules/common/taiga.nix b/modules/common/taiga.nix
index 0f64fb3..85fc4e3 100644
--- a/modules/common/taiga.nix
+++ b/modules/common/taiga.nix
@@ -22,8 +22,8 @@
POSTGRES_USER = "taiga";
POSTGRES_HOST = "172.20.0.1";
- TAIGA_SCHEME = "https";
- TAIGA_DOMAIN = "taiga.clicks.codes";
+ TAIGA_SITES_SCHEME = "https";
+ TAIGA_SITES_DOMAIN = "taiga.clicks.codes";
TAIGA_SUBPATH = "";
EMAIL_BACKEND = "django.core.mail.backends.smtp.EmailBackend";
@@ -43,9 +43,12 @@
# TODO: OPENID_CLIENT_SECRET
];
+ host_static_folder = "/var/taiga/back/static";
+ host_media_folder = "/var/taiga/back/media";
+
backend_volumes = [
- "/var/taiga/back/static:/taiga-back/static"
- "/var/taiga/back/media:/taiga-back/media"
+ "${host_static_folder}:/taiga-back/static"
+ "${host_media_folder}:/taiga-back/media"
];
taiga_version = "latest";
@@ -162,7 +165,9 @@
ports = [ "127.0.0.255:1029:80/tcp" ];
volumes = [
"${./taiga/taiga-gateway.conf}:/etc/nginx/conf.d/default.conf"
- ] ++ backend_volumes;
+ "${host_static_folder}:/taiga/static"
+ "${host_media_folder}:/taiga/media"
+ ];
extraOptions = [ "--network=taiga" ];
};
};