mirror of
https://repository.entgra.net/community/entgra-emqx-docker.git
synced 2025-09-16 23:42:18 +00:00
added config to set exhook url
This commit is contained in:
parent
a556b45c06
commit
903aa172b2
74
configs/emqx_exhook.conf
Normal file
74
configs/emqx_exhook.conf
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
##====================================================================
|
||||||
|
## EMQX Hooks
|
||||||
|
##====================================================================
|
||||||
|
|
||||||
|
## The default value or action will be returned, while the request to
|
||||||
|
## the gRPC server failed or no available grpc server running.
|
||||||
|
##
|
||||||
|
## Default: deny
|
||||||
|
## Value: ignore | deny
|
||||||
|
#exhook.request_failed_action = deny
|
||||||
|
|
||||||
|
## The timeout to request grpc server
|
||||||
|
##
|
||||||
|
## Default: 5s
|
||||||
|
## Value: Duration
|
||||||
|
#exhook.request_timeout = 5s
|
||||||
|
|
||||||
|
## Whether to automatically reconnect (initialize) the gRPC server
|
||||||
|
##
|
||||||
|
## When gRPC is not available, exhook tries to request the gRPC service at
|
||||||
|
## that interval and reinitialize the list of mounted hooks.
|
||||||
|
##
|
||||||
|
## Default: false
|
||||||
|
## Value: false | Duration
|
||||||
|
#exhook.auto_reconnect = 60s
|
||||||
|
|
||||||
|
## The process pool size for gRPC client
|
||||||
|
##
|
||||||
|
## Default: Equals cpu cores
|
||||||
|
## Value: Integer
|
||||||
|
#exhook.pool_size = 16
|
||||||
|
|
||||||
|
## The exhook execution priority on the Chain of the emqx hooks.
|
||||||
|
##
|
||||||
|
## Modify the field to fix the exhook execute order before/after other plugins/modules.
|
||||||
|
## By default, most hooks registered by plugins or modules have a priority of 0.
|
||||||
|
##
|
||||||
|
## With the same priority of 0, the execute order depends on hookpoints mount order.
|
||||||
|
## Scilicet is the loaded order of plugins/ modules.
|
||||||
|
##
|
||||||
|
## Default: 0
|
||||||
|
## Value: Integer
|
||||||
|
#exhook.hook_priority = 0
|
||||||
|
|
||||||
|
##--------------------------------------------------------------------
|
||||||
|
## The Hook callback servers
|
||||||
|
|
||||||
|
## The gRPC server url
|
||||||
|
##
|
||||||
|
## exhook.server.$name.url = url()
|
||||||
|
exhook.server.default.url = http://host.docker.internal:9000
|
||||||
|
|
||||||
|
#exhook.server.default.ssl.cacertfile = etc/certs/cacert.pem
|
||||||
|
#exhook.server.default.ssl.certfile = etc/certs/cert.pem
|
||||||
|
#exhook.server.default.ssl.keyfile = etc/certs/key.pem
|
||||||
|
|
||||||
|
## Enables/disables periodic transmission on a connected socket when no other data is exchanged.
|
||||||
|
## If the other end does not respond, the connection is considered broken and an error message is sent to the controlling process.
|
||||||
|
##
|
||||||
|
## Default: true
|
||||||
|
#exhook.server.default.socket_options.keepalive = true
|
||||||
|
|
||||||
|
## If true, option TCP_NODELAY is turned on for the socket, which means that also small amounts of data are sent immediately.
|
||||||
|
##
|
||||||
|
## Default: true
|
||||||
|
#exhook.server.default.socket_options.nodelay = true
|
||||||
|
|
||||||
|
## The minimum size of the receive buffer to use for the socket.
|
||||||
|
#exhook.server.default.socket_options.recbuf = 64KB
|
||||||
|
|
||||||
|
## The minimum size of the send buffer to use for the socket.
|
||||||
|
#exhook.server.default.socket_options.sndbuf = 16KB
|
||||||
|
|
||||||
|
|
||||||
@ -5,6 +5,8 @@ services:
|
|||||||
image: registry.entgra.io/entgra-emqx:4.4.11
|
image: registry.entgra.io/entgra-emqx:4.4.11
|
||||||
container_name: entgra-emqx
|
container_name: entgra-emqx
|
||||||
restart: always
|
restart: always
|
||||||
|
extra_hosts:
|
||||||
|
- "host.docker.internal:host-gateway"
|
||||||
ports:
|
ports:
|
||||||
- "1883:1883"
|
- "1883:1883"
|
||||||
- "8081:8081"
|
- "8081:8081"
|
||||||
@ -13,8 +15,8 @@ services:
|
|||||||
- "8883:8883"
|
- "8883:8883"
|
||||||
- "18083:18083"
|
- "18083:18083"
|
||||||
volumes:
|
volumes:
|
||||||
# Logs
|
|
||||||
- ./static:/opt/emqx/static
|
- ./static:/opt/emqx/static
|
||||||
|
- ./configs:/opt/emqx/configs
|
||||||
|
|
||||||
# environment:
|
# environment:
|
||||||
# Hostname configurations
|
# Hostname configurations
|
||||||
|
|||||||
@ -5,5 +5,7 @@ STATIC_CONFIG_PATH=/opt/emqx/lib/emqx_dashboard-4.4.10/priv/www/static/
|
|||||||
cp /opt/emqx/static/css/* $STATIC_CONFIG_PATH/css/
|
cp /opt/emqx/static/css/* $STATIC_CONFIG_PATH/css/
|
||||||
cp /opt/emqx/static/img/* $STATIC_CONFIG_PATH/img/
|
cp /opt/emqx/static/img/* $STATIC_CONFIG_PATH/img/
|
||||||
|
|
||||||
|
cp /opt/emqx/configs/emqx_exhook.conf /opt/emqx/etc/plugins/
|
||||||
|
|
||||||
echo "Starting server.."
|
echo "Starting server.."
|
||||||
sh /opt/emqx/bin/emqx foreground
|
sh /opt/emqx/bin/emqx foreground
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user