ahdinosaur / ssb-pub

easily host your own Secure ScuttleButt (SSB) pub in a docker container
http://butt.nz/
GNU Affero General Public License v3.0
158 stars 25 forks source link

Connections need to be adjusted for viewer #31

Open black-puppydog opened 4 years ago

black-puppydog commented 4 years ago

I had trouble doing npm install for ssb-viewer (manual setup) because port 8989 could not be reached for retrieving some blobs. So I had to add that connection to the config file. While I was at it, I also changed the host fields to :: instead of 0.0.0.0. There might be issues with this, see https://github.com/ssbc/ssb-config/pull/53, but for me it works.

Full config after modification:

{
  "plugins": {
    "ssb-viewer": true
  },
  "viewer": {
    "host": "::"
  },
  "connections": {
    "incoming": {
      "net": [
        {
          "scope": ["device", "public"],
          "host": "::",
          "external": ["muchmuch.coffee"],
          "transform": "shs",
          "port": 8008
        }
      ],
      "ws":[
        { "host": "::",
          "port": 8989,
          "scope": [ "device", "local", "public" ],
          "transform": "shs" } ]
    },
    "outgoing": {
      "net": [
        {
          "transform": "shs"
        }
      ]
    }
  }
}

Not sure if the scope fields are at the right values honestly, but since everything has "transform": "shs" I should be fine, right?