Merge "app/matrix: upgrade and migrate to official appservice-irc image"
diff --git a/app/matrix/appservice-irc.yaml b/app/matrix/appservice-irc.yaml
index b49d11c..cc65926 100644
--- a/app/matrix/appservice-irc.yaml
+++ b/app/matrix/appservice-irc.yaml
@@ -381,11 +381,6 @@
       - "1d"
       - "1w"
 
-  # The nedb database URI to connect to. This is the name of the directory to
-  # dump .db files to. This is relative to the project directory.
-  # Required.
-  databaseUri: "nedb://data"
-
   # Configuration options for the debug HTTP API. To access this API, you must
   # append ?access_token=$APPSERVICE_TOKEN (from the registration file) to the requests.
   #
@@ -443,3 +438,7 @@
   # accidentally overloading the homeserver. Defaults to 1000, which should be
   # enough for the vast majority of use cases.
   maxHttpSockets: 1000
+
+database:
+  engine: "nedb"
+  connectionString: "nedb:///data"
diff --git a/app/matrix/prod.jsonnet b/app/matrix/prod.jsonnet
index 0234a7d..e9d43be 100644
--- a/app/matrix/prod.jsonnet
+++ b/app/matrix/prod.jsonnet
@@ -278,7 +278,7 @@
         local bridge = self,
         local cfg = bridge.cfg,
         cfg:: {
-            image: "registry.k0.hswaw.net/informatic/matrix-appservice-irc:0.12.0",
+            image: "matrixdotorg/matrix-appservice-irc:release-0.16.0",
             metadata: {},
             config: std.native("parseYaml")(importstr "appservice-irc.yaml")[0],
             storageClassName: app.cfg.storageClassName,
@@ -319,7 +319,7 @@
                         containers_: {
                             bootstrap: kube.Container("appservice-irc-%s-bootstrap" % [name]) {
                                 image: cfg.image,
-                                command: ["sh", "-c", "matrix-appservice-irc -r -u http://appservice-irc-%s:9999 -c /config/config.yaml -f /tmp/registration.yaml && cat /tmp/registration.yaml" % [name]],
+                                command: ["sh", "-c", "node app.js -r -u http://appservice-irc-%s:9999 -c /config/config.yaml -f /tmp/registration.yaml && cat /tmp/registration.yaml" % [name]],
                                 volumeMounts_: {
                                     config: { mountPath: "/config" },
                                 },
@@ -345,7 +345,7 @@
                         containers_: {
                             appserviceIrc: kube.Container("appservice-irc-%s" % [name]) {
                                 image: cfg.image,
-                                command: ["matrix-appservice-irc", "-c", "/config/config.yaml", "-f", "/registration/registration.yaml", "-p", "9999"],
+                                command: ["node", "app.js", "-c", "/config/config.yaml", "-f", "/registration/registration.yaml", "-p", "9999"],
                                 ports_: {
                                     http: { containerPort: 9999 },
                                 },