The Docker image is hosted on the GitHub container registry and is ready to be used:
docker pull ghcr.io/blabtm/emqx-gate:latest
The following configuration properties are required in order to properly setup extension:
- PORT - host port on which service will be started (default: 9001)
- EMQX_ADAPTER_HOST - EMQX hostname at which ConnectionAdapter will be started (default: emqx)
- EMQX_ADAPTER_PORT - EMQX port number at which ConnectionAdapter will be started (default: 9100)
Below is a minimum viable stack file (example/compose.yaml):
networks:
stage:
name: stage
driver: bridge
services:
emqx:
image: ghcr.io/blabtm/emqx:latest
ports:
- 1883:1883
- 18083:18083
- 20041:20041
networks:
- stage
emqx-gate:
image: ghcr.io/blabtm/emqx-gate:latest
environment:
PORT: 9001
EMQX_ADAPTER_HOST: emqx
EMQX_ADAPTER_PORT: 9100
networks:
- stage
When the server starts, see the log output to determine the
MACHINE
address.
To add gateway instance:
- Login to EMQX Dashboard
- Go to Management -> Gateways
- Click
Setup
opposite the ExProto - Configure the gateway:
- gRPC ConnectionAdapter - Bind:
0.0.0.0:{EMQX_ADAPTER_PORT}
- gRPC ConnectionHandler - Server:
http://{MACHINE}:{PORT}
- gRPC ConnectionAdapter - Bind:
- Go
Next
- Setup
default
listener:- Type:
tcp
- Bind:
20041
- Type:
- Go
Update
->Next
->Enable
Enjoy!