Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
version: '3.5'
services:
  
  bgw:
    image: "linksmart/bgw:latest"
    deploy:
      replicas: 1    
    container_name: "bgw"
    depends_on:
      - redis
    ports:
      - 443:443
      - 8883:8883
      - 9002:9002
    secrets:
      - source: bgw-ssl.cert
        target: "/bgw/certs/<your_cert>.pem"
      - source: bgw-ssl.key
        target: "/bgw/certs/<your_key>.pem"
    configs:
      - source: config
        target: "/bgw/config/config.toml"

  redis:
    deploy:
      replicas: 1
    image: redis:5-alpine
    ports:
      - 6379:6379

secrets:
  bgw-ssl.cert:
    file: "./certs/<your_cert>.pem"
  bgw-ssl.key:
    file: "./certs/<your_key>.pem"
configs:
  config:
    file: "./config.toml"

...

Redis as an access token cache

You need to set up key-value database Redis to cache access tokens for connections using username / password. The BGW auth service will store keys and values in Redis like this:

...