webhooksite. Adding Redis to stack.
All checks were successful
continuous-integration/drone/pr Build is passing

This commit is contained in:
Alexey Skobkin 2024-03-07 16:26:35 +03:00
parent 020f498c74
commit e4783097aa
No known key found for this signature in database
GPG key ID: 5D5CEF6F221278E7
3 changed files with 20 additions and 3 deletions

View file

@ -13,7 +13,7 @@ APP_DEBUG=false
APP_URL=http://domain.tld:80 APP_URL=http://domain.tld:80
APP_LOG=errorlog APP_LOG=errorlog
DB_CONNECTION=sqlite DB_CONNECTION=sqlite
REDIS_HOST=host.docker.internal REDIS_HOST=redis
REDIS_PORT=6379 REDIS_PORT=6379
#REDIS_PASSWORD=null #REDIS_PASSWORD=null
BROADCAST_DRIVER=redis BROADCAST_DRIVER=redis
@ -21,5 +21,7 @@ CACHE_DRIVER=redis
QUEUE_DRIVER=redis QUEUE_DRIVER=redis
ECHO_HOST_MODE=path ECHO_HOST_MODE=path
REDIS_HOST_DATA_DIR=./data
LOG_MAX_SIZE=5m LOG_MAX_SIZE=5m
LOG_MAX_FILE=5 LOG_MAX_FILE=5

2
webhooksite/data/.gitignore vendored Normal file
View file

@ -0,0 +1,2 @@
/*
!/.gitignore

View file

@ -6,8 +6,6 @@ services:
image: "webhooksite/webhook.site" image: "webhooksite/webhook.site"
container_name: webhook-site container_name: webhook-site
command: "php artisan queue:work --daemon --tries=3 --timeout=10" command: "php artisan queue:work --daemon --tries=3 --timeout=10"
extra_hosts:
- 'host.docker.internal:host-gateway'
ports: ports:
- "${WEBUI_BIND_ADDR}:${WEBUI_BIND_PORT}:80" - "${WEBUI_BIND_ADDR}:${WEBUI_BIND_PORT}:80"
env_file: .env env_file: .env
@ -20,6 +18,8 @@ services:
laravel-echo-server: laravel-echo-server:
image: "webhooksite/laravel-echo-server" image: "webhooksite/laravel-echo-server"
depends_on:
- redis
ports: ports:
- "${ECHO_BIND_ADDR:-127.0.0.1}:${ECHO_BIND_PORT:-6001}:${ECHO_BIND_PORT:-6001}" - "${ECHO_BIND_ADDR:-127.0.0.1}:${ECHO_BIND_PORT:-6001}:${ECHO_BIND_PORT:-6001}"
environment: environment:
@ -33,3 +33,16 @@ services:
- "ECHO_ALLOW_ORIGIN=*" - "ECHO_ALLOW_ORIGIN=*"
- "ECHO_ALLOW_METHODS=*" - "ECHO_ALLOW_METHODS=*"
- "ECHO_ALLOW_HEADERS=*" - "ECHO_ALLOW_HEADERS=*"
redis:
image: redis:alpine
command: "redis-server --save ${PERSISTENCE_PERIOD_SEC:-60} ${PERSISTENCE_MIN_OPS:-1} --loglevel ${LOG_LEVEL:-warning}"
volumes:
- "${REDIS_HOST_DATA_DIR:-./data}:/data"
env_file: .env
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "${LOG_MAX_SIZE:-5m}"
max-file: "${LOG_MAX_FILE:-5}"