mirror of
https://repository.entgra.net/community/entgra-emqx-docker.git
synced 2025-09-16 23:42:18 +00:00
Add Env variable for exhook.server.default.url in configs
This commit is contained in:
parent
c88adc8626
commit
5ee07c57a9
@ -12,4 +12,7 @@ COPY /data/loaded_plugins /opt/emqx/data/
|
|||||||
|
|
||||||
EXPOSE 1883 8083 8084 8883 11883 18083 4370 5369
|
EXPOSE 1883 8083 8084 8883 11883 18083 4370 5369
|
||||||
|
|
||||||
ENTRYPOINT ["sh", "/opt/emqx/bin/emqx", "foreground"]
|
COPY ./entrypoint.sh /opt/emqx/bin/entrypoint.sh
|
||||||
|
USER root
|
||||||
|
RUN chmod +x /opt/emqx/bin/entrypoint.sh
|
||||||
|
ENTRYPOINT ["/opt/emqx/bin/entrypoint.sh"]
|
||||||
|
|||||||
@ -48,7 +48,7 @@
|
|||||||
## The gRPC server url
|
## The gRPC server url
|
||||||
##
|
##
|
||||||
## exhook.server.$name.url = url()
|
## exhook.server.$name.url = url()
|
||||||
exhook.server.default.url = http://switch-gear:9000
|
exhook.server.default.url = http://${SG_HOSTNAME}:9000
|
||||||
|
|
||||||
#exhook.server.default.ssl.cacertfile = etc/certs/cacert.pem
|
#exhook.server.default.ssl.cacertfile = etc/certs/cacert.pem
|
||||||
#exhook.server.default.ssl.certfile = etc/certs/cert.pem
|
#exhook.server.default.ssl.certfile = etc/certs/cert.pem
|
||||||
|
|||||||
@ -18,9 +18,9 @@ services:
|
|||||||
- ./static:/opt/emqx/static
|
- ./static:/opt/emqx/static
|
||||||
- ./configs:/opt/emqx/configs
|
- ./configs:/opt/emqx/configs
|
||||||
|
|
||||||
# environment:
|
environment:
|
||||||
# Hostname configurations
|
# Hostname configurations
|
||||||
# - MGT_HOSTNAME=localhost
|
- SG_HOSTNAME=switchgear
|
||||||
# - MGT_HTTPS_PORT=9443
|
# - MGT_HTTPS_PORT=9443
|
||||||
# - MGT_HTTP_PORT=9763
|
# - MGT_HTTP_PORT=9763
|
||||||
#
|
#
|
||||||
|
|||||||
9
entrypoint.sh
Normal file
9
entrypoint.sh
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
CONFIG_PATH=/opt/emqx/etc/plugins/emqx_exhook.conf
|
||||||
|
|
||||||
|
# Set emqx_exhook.conf configs
|
||||||
|
sed -i 's/${SG_HOSTNAME}/'$SG_HOSTNAME'/g' $CONFIG_PATH
|
||||||
|
|
||||||
|
echo "Starting server.."
|
||||||
|
sh /opt/emqx/bin/emqx foreground
|
||||||
Loading…
Reference in New Issue
Block a user