Sergiusz Bazanski | 6f773e0 | 2019-10-02 20:46:48 +0200 | [diff] [blame] | 1 | local mirko = import "../../kube/mirko.libsonnet"; |
| 2 | local kube = import "../../kube/kube.libsonnet"; |
| 3 | |
Sergiusz Bazanski | d0ec2c6 | 2019-11-21 00:08:52 +0100 | [diff] [blame] | 4 | local smsgw = import "smsgw.libsonnet"; |
| 5 | local ldapweb = import "ldapweb.libsonnet"; |
Sergiusz Bazanski | c315aac | 2020-01-02 16:43:39 +0100 | [diff] [blame] | 6 | local teleimg = import "teleimg.libsonnet"; |
Sergiusz Bazanski | d0ec2c6 | 2019-11-21 00:08:52 +0100 | [diff] [blame] | 7 | |
Sergiusz Bazanski | 6f773e0 | 2019-10-02 20:46:48 +0200 | [diff] [blame] | 8 | { |
| 9 | hswaw(name):: mirko.Environment(name) { |
| 10 | local env = self, |
| 11 | local cfg = self.cfg, |
| 12 | |
| 13 | cfg+: { |
Sergiusz Bazanski | d0ec2c6 | 2019-11-21 00:08:52 +0100 | [diff] [blame] | 14 | smsgw: smsgw.cfg, |
| 15 | ldapweb: ldapweb.cfg, |
Sergiusz Bazanski | c315aac | 2020-01-02 16:43:39 +0100 | [diff] [blame] | 16 | teleimg: teleimg.cfg, |
Sergiusz Bazanski | 6f773e0 | 2019-10-02 20:46:48 +0200 | [diff] [blame] | 17 | }, |
| 18 | |
| 19 | components: { |
Sergiusz Bazanski | d0ec2c6 | 2019-11-21 00:08:52 +0100 | [diff] [blame] | 20 | smsgw: smsgw.component(cfg.smsgw, env), |
| 21 | ldapweb: ldapweb.component(cfg.ldapweb, env), |
Sergiusz Bazanski | a885488 | 2020-01-05 00:34:38 +0100 | [diff] [blame] | 22 | teleimg: teleimg.teleimg(cfg.teleimg, env), |
| 23 | lelegram: teleimg.lelegram(cfg.teleimg, env), |
Sergiusz Bazanski | 6f773e0 | 2019-10-02 20:46:48 +0200 | [diff] [blame] | 24 | }, |
| 25 | }, |
| 26 | |
| 27 | prod: self.hswaw("hswaw-prod") { |
| 28 | cfg+: { |
| 29 | smsgw+: { |
| 30 | secret+: { |
| 31 | twilio_token: std.base64(std.split(importstr "secrets/plain/prod-twilio-token", "\n")[0]), |
| 32 | }, |
| 33 | webhookFQDN: "smsgw-webhook-prod.hswaw.net", |
Sergiusz Bazanski | 5b86662 | 2019-10-18 14:54:36 +0200 | [diff] [blame] | 34 | }, |
| 35 | ldapweb+: { |
Sergiusz Bazanski | 831a54a | 2019-10-20 17:38:22 +0200 | [diff] [blame] | 36 | webFQDN: "profile.hackerspace.pl", |
Sergiusz Bazanski | 5b86662 | 2019-10-18 14:54:36 +0200 | [diff] [blame] | 37 | }, |
Sergiusz Bazanski | c315aac | 2020-01-02 16:43:39 +0100 | [diff] [blame] | 38 | teleimg+: { |
| 39 | webFQDN: "teleimg.hswaw.net", |
| 40 | secret+: { |
| 41 | telegram_token: std.base64(std.split(importstr "secrets/plain/prod-telegram-token", "\n")[0]), |
| 42 | }, |
| 43 | }, |
Sergiusz Bazanski | 6f773e0 | 2019-10-02 20:46:48 +0200 | [diff] [blame] | 44 | }, |
| 45 | }, |
| 46 | } |