apiVersion: v1
kind: ConfigMap
metadata:
  name: crossbar-config
data:
  config.json: |-
    {
      "version": 2,
      "controller": {},
      "workers": [
        {
          "type": "router",
          "realms": [
            {
              "name": "realm1",
              "roles": [
                {
                  "name": "anonymous",
                  "permissions": [
                    {
                      "uri": "",
                      "match": "prefix",
                      "allow": {
                        "call": true,
                        "register": true,
                        "publish": true,
                        "subscribe": true
                      },
                      "disclose": {
                        "caller": false,
                        "publisher": false
                      },
                      "cache": true
                    }
                  ]
                }
              ]
            }
          ],
          "transports": [
            {
              "type": "universal",
              "endpoint": {
                "type": "tcp",
                "port": 8080
              },
              "rawsocket": {
              },
              "websocket": {
                "ws": {
                  "type": "websocket"
                }
              },
              "web": {
                "paths": {
                  "/": {
                    "type": "static",
                    "directory": ".."
                  }
                }
              }
            }
          ]
        }
      ]
    }
