aboutsummaryrefslogtreecommitdiff
path: root/app/deployment
diff options
context:
space:
mode:
authorQuentin <quentin@deuxfleurs.fr>2020-12-22 14:31:42 +0100
committerQuentin <quentin@deuxfleurs.fr>2020-12-22 14:31:42 +0100
commite628dc44bac9492173c4800c8b999a82b6c55b71 (patch)
treedbafb5a2354e67f5526844ae90ac1393494ddc52 /app/deployment
parent846449b2383d8ff3041be2d035017047090dcaef (diff)
downloadinfrastructure-e628dc44bac9492173c4800c8b999a82b6c55b71.tar.gz
infrastructure-e628dc44bac9492173c4800c8b999a82b6c55b71.zip
Migrate seafile
Diffstat (limited to 'app/deployment')
-rw-r--r--app/deployment/seafile.hcl55
1 files changed, 26 insertions, 29 deletions
diff --git a/app/deployment/seafile.hcl b/app/deployment/seafile.hcl
index 75d752a..8e2480a 100644
--- a/app/deployment/seafile.hcl
+++ b/app/deployment/seafile.hcl
@@ -10,6 +10,14 @@ job "seafile" {
group "main" {
count = 1
+
+ network {
+ port "seafile-frontend" { static = 8000 }
+ port "seafile-seafhttp" { static = 8083 }
+ port "seafile-dav" { static = 8084 }
+ port "seafile-hack" { static = 8085 }
+ }
+
task "hack" {
driver = "docker"
config {
@@ -125,55 +133,44 @@ job "seafile" {
}
}
- artifact {
- source = "http://127.0.0.1:8500/v1/kv/configuration/seafile/conf/ccnet.conf.tpl?raw"
- destination = "secrets/conf/ccnet.conf.tpl"
- mode = "file"
- }
- template {
- source = "secrets/conf/ccnet.conf.tpl"
+ template {
+ data = file("../config/configuration/seafile/conf/ccnet.conf.tpl")
destination = "secrets/conf/ccnet.conf"
}
- artifact {
- source = "http://127.0.0.1:8500/v1/kv/configuration/seafile/conf/seafile.conf.tpl?raw"
- destination = "secrets/conf/seafile.conf.tpl"
- mode = "file"
- }
template {
- source = "secrets/conf/seafile.conf.tpl"
+ data = file("../config/configuration/seafile/conf/seafile.conf.tpl")
destination = "secrets/conf/seafile.conf"
}
- artifact {
- source = "http://127.0.0.1:8500/v1/kv/configuration/seafile/conf/seahub_settings.py.tpl?raw"
- destination = "secrets/conf/seahub_settings.py.tpl"
- mode = "file"
- }
template {
- source = "secrets/conf/seahub_settings.py.tpl"
+ data = file("../config/configuration/seafile/conf/seahub_settings.py.tpl")
destination = "secrets/conf/seahub_settings.py"
}
template {
- data = "{{ key \"configuration/seafile/ccnet/mykey.peer\" }}"
- destination = "secrets/ccnet/mykey.peer"
+ data = file("../config/configuration/seafile/ccnet/seafile.ini")
+ destination = "secrets/ccnet/seafile.ini"
}
template {
- data = "{{ key \"configuration/seafile/ccnet/seafile.ini\" }}"
- destination = "secrets/ccnet/seafile.ini"
+ data = file("../config/configuration/seafile/conf/seafdav.conf")
+ destination = "secrets/conf/seafdav.conf"
}
template {
- data = "{{ key \"configuration/seafile/conf/mykey.peer\" }}"
- destination = "secrets/conf/mykey.peer"
+ data = file("../config/configuration/seafile/conf/gunicorn.conf")
+ destination = "secrets/conf/gunicorn.conf"
}
+
+ # ---- secrets ----
+ # @FIXME should be put in the secret hierarchy in consul
template {
- data = "{{ key \"configuration/seafile/conf/seafdav.conf\" }}"
- destination = "secrets/conf/seafdav.conf"
+ data = "{{ key \"configuration/seafile/conf/mykey.peer\" }}"
+ destination = "secrets/ccnet/mykey.peer"
}
+
template {
- data = "{{ key \"configuration/seafile/conf/gunicorn.conf\" }}"
- destination = "secrets/conf/gunicorn.conf"
+ data = "{{ key \"configuration/seafile/conf/mykey.peer\" }}"
+ destination = "secrets/conf/mykey.peer"
}
}
}