aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.travis.yml2
-rw-r--r--dhall-1.26.1.nix (renamed from dhall-1.21.0.nix)2
-rw-r--r--dhall/Addon.dhall6
-rw-r--r--dhall/Config.dhall62
-rw-r--r--dhall/addon/Addon.dhall1
-rw-r--r--dhall/addon/Postgresql.dhall3
-rw-r--r--dhall/addon/functions.dhall1
-rw-r--r--dhall/functions.dhall1
-rw-r--r--dhall/mkConfig.dhall33
-rw-r--r--dhall/package.dhall1
-rw-r--r--dhall/types.dhall1
11 files changed, 46 insertions, 67 deletions
diff --git a/.travis.yml b/.travis.yml
index 3004369..4f5d09c 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -5,7 +5,7 @@ sudo: false
5 5
6install: 6install:
7 - nix-env -i python2.7-ansible python2.7-ansible-lint ShellCheck-0.7.0 7 - nix-env -i python2.7-ansible python2.7-ansible-lint ShellCheck-0.7.0
8 - nix-env -if ./dhall-1.21.0.nix 8 - nix-env -if ./dhall-1.26.1.nix
9 9
10 # Check ansible version 10 # Check ansible version
11 - ansible --version 11 - ansible --version
diff --git a/dhall-1.21.0.nix b/dhall-1.26.1.nix
index e53369b..918a528 100644
--- a/dhall-1.21.0.nix
+++ b/dhall-1.26.1.nix
@@ -19,4 +19,4 @@ let
19 ''; 19 '';
20 }; 20 };
21in 21in
22 mkVersion "1.21.0" "0x7q6v1y62fq6724kx1hcfp1fcqv3lbv33ji6jzfd5y316a31r77" 22 mkVersion "1.26.1" "0sl4r3mfairgd6kn26hs1r1lkh8rn992grd73078rhqf5w90ag05"
diff --git a/dhall/Addon.dhall b/dhall/Addon.dhall
new file mode 100644
index 0000000..76d2c80
--- /dev/null
+++ b/dhall/Addon.dhall
@@ -0,0 +1,6 @@
1let Addon = < Postgresql : { name : Text, env_prefix : Text } >
2
3let postgresql =
4 Addon.Postgresql { name = "pg", env_prefix = "POSTGRESQL_ADDON" }
5
6in { Type = Addon, postgresql = postgresql }
diff --git a/dhall/Config.dhall b/dhall/Config.dhall
index 5b7eab2..1b9388e 100644
--- a/dhall/Config.dhall
+++ b/dhall/Config.dhall
@@ -1,26 +1,38 @@
1let Addon = ./addon/Addon.dhall 1let Addon = (./Addon.dhall).Type
2 2
3in λ(Environment : Type) 3let Vault = ./Vault.dhall
4 → { clever_app : 4
5 Text 5let Config =
6 , clever_orga : 6 λ(Environment : Type)
7 Text 7 → { clever_app : Text
8 , clever_secret : 8 , clever_orga : Text
9 Text 9 , clever_secret : Text
10 , clever_token : 10 , clever_token : Text
11 Text 11 , clever_syslog_server : Optional Text
12 , clever_syslog_server : 12 , clever_domain : Optional Text
13 Optional Text 13 , clever_app_tasks_file : Optional Text
14 , clever_domain : 14 , clever_haskell_entry_point : Optional Text
15 Optional Text 15 , clever_disable_metrics : Bool
16 , clever_app_tasks_file : 16 , clever_addons : List Addon
17 Optional Text 17 , clever_env : Environment
18 , clever_haskell_entry_point : 18 }
19 Optional Text 19
20 , clever_disable_metrics : 20let mkConfig =
21 Bool 21 λ(vault : Vault)
22 , clever_addons : 22 → λ(app : Text)
23 List Addon 23 → λ(organization : Text)
24 , clever_env : 24 → { clever_app = app
25 Environment 25 , clever_orga = organization
26 } 26 , clever_secret = vault.secret
27 , clever_token = vault.token
28 , clever_syslog_server = None Text
29 , clever_domain = None Text
30 , clever_app_tasks_file = None Text
31 , clever_haskell_entry_point = None Text
32 , clever_disable_metrics = False
33 , clever_addons = [] : List Addon
34 , clever_env = {=}
35 }
36 : Config {}
37
38in { Type = Config, mkConfig = mkConfig }
diff --git a/dhall/addon/Addon.dhall b/dhall/addon/Addon.dhall
deleted file mode 100644
index 2eb781c..0000000
--- a/dhall/addon/Addon.dhall
+++ /dev/null
@@ -1 +0,0 @@
1< Postgresql : { name : Text, env_prefix : Text } >
diff --git a/dhall/addon/Postgresql.dhall b/dhall/addon/Postgresql.dhall
deleted file mode 100644
index ed6b411..0000000
--- a/dhall/addon/Postgresql.dhall
+++ /dev/null
@@ -1,3 +0,0 @@
1let addon = ./Addon.dhall
2
3in addon.Postgresql { name = "pg", env_prefix = "POSTGRESQL_ADDON" }
diff --git a/dhall/addon/functions.dhall b/dhall/addon/functions.dhall
deleted file mode 100644
index 65979ac..0000000
--- a/dhall/addon/functions.dhall
+++ /dev/null
@@ -1 +0,0 @@
1{ Postgresql = ./Postgresql.dhall }
diff --git a/dhall/functions.dhall b/dhall/functions.dhall
deleted file mode 100644
index f047c19..0000000
--- a/dhall/functions.dhall
+++ /dev/null
@@ -1 +0,0 @@
1{ Addon = ./addon/functions.dhall, mkConfig = ./mkConfig.dhall }
diff --git a/dhall/mkConfig.dhall b/dhall/mkConfig.dhall
deleted file mode 100644
index d2ec034..0000000
--- a/dhall/mkConfig.dhall
+++ /dev/null
@@ -1,33 +0,0 @@
1let Config = ./Config.dhall
2
3let Vault = ./Vault.dhall
4
5let Addon = ./addon/Addon.dhall
6
7in λ(vault : Vault)
8 → λ(app : Text)
9 → λ(organization : Text)
10 → { clever_app =
11 app
12 , clever_orga =
13 organization
14 , clever_secret =
15 vault.secret
16 , clever_token =
17 vault.token
18 , clever_syslog_server =
19 None Text
20 , clever_domain =
21 None Text
22 , clever_app_tasks_file =
23 None Text
24 , clever_haskell_entry_point =
25 None Text
26 , clever_disable_metrics =
27 False
28 , clever_addons =
29 [] : List Addon
30 , clever_env =
31 {=}
32 }
33 : Config {}
diff --git a/dhall/package.dhall b/dhall/package.dhall
new file mode 100644
index 0000000..c653ddb
--- /dev/null
+++ b/dhall/package.dhall
@@ -0,0 +1 @@
{ Addon = ./Addon.dhall, Config = ./Config.dhall, Vault = ./Vault.dhall }
diff --git a/dhall/types.dhall b/dhall/types.dhall
deleted file mode 100644
index ab153d2..0000000
--- a/dhall/types.dhall
+++ /dev/null
@@ -1 +0,0 @@
1{ Vault = ./Vault.dhall, Addon = ./addon/Addon.dhall, Config = ./Config.dhall }