mirror of
https://github.com/valitydev/limiter.git
synced 2024-11-06 00:55:22 +00:00
9bf3e29636
* draft * added format * added backend stuff * added requested changes except batch in range machine * added error sort in handler, add lim_body and its validation * added start time and shard size, implemented shard id generation and time range calculation * fixed xref * fixed format * added unit tests * refactored errors * updated to new proto * added config marshaling * fixed format * added base tests * added exchange tests * fixed linter * added requested changes * updated proto ref
61 lines
1.6 KiB
Bash
Executable File
61 lines
1.6 KiB
Bash
Executable File
#!/bin/bash
|
|
cat <<EOF
|
|
version: '2.1'
|
|
services:
|
|
|
|
${SERVICE_NAME}:
|
|
image: ${BUILD_IMAGE}
|
|
volumes:
|
|
- .:$PWD
|
|
- $HOME/.cache:/home/$UNAME/.cache
|
|
working_dir: $PWD
|
|
command: /sbin/init
|
|
depends_on:
|
|
machinegun:
|
|
condition: service_healthy
|
|
shumway:
|
|
condition: service_healthy
|
|
|
|
machinegun:
|
|
image: dr2.rbkmoney.com/rbkmoney/machinegun:0da2ffc23221e1e3f8557b03d48d11d2dd18fac0
|
|
command: /opt/machinegun/bin/machinegun foreground
|
|
volumes:
|
|
- ./test/machinegun/config.yaml:/opt/machinegun/etc/config.yaml
|
|
- ./test/log/machinegun:/var/log/machinegun
|
|
- ./test/machinegun/cookie:/opt/machinegun/etc/cookie
|
|
healthcheck:
|
|
test: "curl http://localhost:8022/"
|
|
interval: 5s
|
|
timeout: 1s
|
|
retries: 10
|
|
|
|
shumway:
|
|
image: dr2.rbkmoney.com/rbkmoney/shumway:e946e83703e02f4359cd536b15fb94457f9bfb20
|
|
restart: unless-stopped
|
|
entrypoint:
|
|
- java
|
|
- -Xmx512m
|
|
- -jar
|
|
- /opt/shumway/shumway.jar
|
|
- --spring.datasource.url=jdbc:postgresql://shumway-db:5432/shumway
|
|
- --spring.datasource.username=postgres
|
|
- --spring.datasource.password=postgres
|
|
- --management.metrics.export.statsd.enabled=false
|
|
depends_on:
|
|
- shumway-db
|
|
healthcheck:
|
|
test: "curl http://localhost:8022/actuator/health"
|
|
interval: 5s
|
|
timeout: 1s
|
|
retries: 20
|
|
|
|
shumway-db:
|
|
image: dr2.rbkmoney.com/rbkmoney/postgres:9.6
|
|
environment:
|
|
- POSTGRES_DB=shumway
|
|
- POSTGRES_USER=postgres
|
|
- POSTGRES_PASSWORD=postgres
|
|
- SERVICE_NAME=shumway-db
|
|
|
|
EOF
|