Skip to content

Commit cedb030

Browse files
authored
Merge pull request #139 from Drill4J/release/0.10.0
Release/0.10.0
2 parents 6a482b8 + a79bcb6 commit cedb030

32 files changed

Lines changed: 4710 additions & 542 deletions
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
services:
2+
3+
my-app:
4+
image: my-app:${MY_APP_VERSION}
5+
environment:
6+
# Instructs Java to load agent files from shared volume directory.
7+
# Remember to set the rest of parameters according to Drill4J Java Agent docs
8+
- "JAVA_TOOL_OPTIONS=-agentpath:/data/agent/libdrill_agent.so"
9+
volumes:
10+
# Mount volume with agent files to your app's container
11+
- agent-files:/data
12+
depends_on:
13+
download-agent-files:
14+
condition: service_completed_successfully
15+
16+
# Launches script to download agent files and places them in shared volume
17+
download-agent-files:
18+
image: drill4j/java-agent:0.8.0-38 # ignore this. Its the version for the _download script_, not the agent
19+
environment:
20+
# ! set the desired agent version here !
21+
- AGENT_VERSION=0.9.20
22+
# ! set the desired agent version here !
23+
volumes:
24+
- agent-files:/data
25+
healthcheck:
26+
# container will return once download is complete
27+
test: ["CMD", "sh", "-c", "test -f /data/agent/libdrill_agent.so || exit 1"]
28+
interval: 30s
29+
retries: 6
30+
start_period: 10s
31+
timeout: 10s
32+
33+
# remember to add named volume
34+
volumes:
35+
agent-files:
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
services:
2+
3+
drill-ui:
4+
image: ghcr.io/drill4j/drill4j-ui:${DRILL_UI_VERSION}
5+
environment:
6+
API_HOST: host.docker.internal
7+
API_PORT: 8090
8+
extra_hosts:
9+
- "host.docker.internal:host-gateway"
10+
ports:
11+
- "8091:8080"
12+
13+
drill-admin:
14+
image: ghcr.io/drill4j/admin:${DRILL_ADMIN_BACKEND_VERSION}
15+
environment:
16+
- DRILL_METRICS_UI_BASE_URL=${DRILL_UI_BASE_URL}
17+
- DRILL_DB_PORT=5432
18+
- DRILL_AGENTS_SOCKET_TIMEOUT=6000
19+
- DRILL_DB_HOST=${POSTGRES_HOST}
20+
- DRILL_DB_NAME=${POSTGRES_DB}
21+
- DRILL_DB_USER_NAME=${POSTGRES_USER}
22+
- DRILL_DB_PASSWORD=${POSTGRES_PASSWORD}
23+
- DRILL_DB_MAX_POOL_SIZE=${DRILL_ADMIN_BACKEND_DB_MAX_POOL_SIZE}
24+
- LOG_LEVEL=info
25+
healthcheck:
26+
test: [ "CMD", "curl", "http://localhost:8090" ]
27+
interval: 10s
28+
timeout: 3s
29+
retries: 30
30+
logging:
31+
driver: "json-file"
32+
options:
33+
max-size: "10m"
34+
max-file: "5"
35+
ports:
36+
- 8090:8090
37+
depends_on:
38+
postgres:
39+
condition: service_healthy
40+
41+
postgres:
42+
image: postgres:17.0
43+
shm_size: 1g
44+
ports:
45+
- '5432:5432'
46+
environment:
47+
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
48+
POSTGRES_USER: ${POSTGRES_USER}
49+
POSTGRES_DB: ${POSTGRES_DB}
50+
volumes:
51+
# Volume to initialize Metabase dashboards
52+
# Place data.sql file from the https://github.com/Drill4J/drill-metabase-dashboards/releases to db-init directory
53+
- ./db-init:/docker-entrypoint-initdb.d
54+
# Volume to store application metrics
55+
- drill-data-pg:/var/lib/postgresql/data
56+
healthcheck:
57+
test: ['CMD-SHELL', 'pg_isready -U postgres']
58+
interval: 10s
59+
timeout: 5s
60+
retries: 5
61+
logging:
62+
driver: "json-file"
63+
options:
64+
max-size: "10m"
65+
max-file: "5"
66+
command: ["postgres", "-c", "log_statement=all", "-c", "log_min_duration_statement=0"]
67+
68+
# This container launches script to either create or update Metabase dashboards
69+
# WARNING: it removes all previously created Metabase dashboards and users
70+
# comment this out if you'd like to keep your edits / customizations
71+
drill-metabase-dashboards-migration:
72+
image: ghcr.io/drill4j/drill-metabase-dashboards:${DRILL_METABASE_DASHBOARDS_VERSION}
73+
environment:
74+
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
75+
POSTGRES_HOST: postgres
76+
POSTGRES_PORT: 5432
77+
POSTGRES_USER: ${POSTGRES_USER}
78+
POSTGRES_DB: ${METABASE_POSTGRES_DB} # its preferable to specify DB different from where Drill4J data is stored. E.g. db-metabase
79+
extra_hosts:
80+
- "host.docker.internal:host-gateway"
81+
depends_on:
82+
postgres:
83+
condition: service_healthy
84+
85+
metabase:
86+
image: metabase/metabase:v0.53.7.x
87+
container_name: metabase
88+
hostname: metabase
89+
volumes:
90+
# Required to share urandom from host machine to speedup startup (see https://github.com/metabase/metabase/issues/10175, https://ruleoftech.com/2016/avoiding-jvm-delays-caused-by-random-number-generation)
91+
- /dev/urandom:/dev/random:ro
92+
ports:
93+
- 8095:3000
94+
environment:
95+
MB_DB_TYPE: postgres
96+
MB_DB_HOST: postgres
97+
MB_DB_PORT: 5432
98+
MB_DB_USER: ${POSTGRES_USER}
99+
MB_DB_PASS: ${POSTGRES_PASSWORD}
100+
MB_DB_DBNAME: ${METABASE_POSTGRES_DB}
101+
healthcheck:
102+
test: curl --fail -I http://localhost:3000/api/health || exit 1
103+
interval: 15s
104+
timeout: 5s
105+
retries: 5
106+
depends_on:
107+
drill-metabase-dashboards-migration:
108+
condition: service_completed_successfully
109+
110+
volumes:
111+
drill-data-pg:
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
DRILL_ADMIN_BACKEND_VERSION=0.10.0
2+
DRILL_UI_VERSION=0.10.0
3+
DRILL_ADMIN_BACKEND_DB_MAX_POOL_SIZE=50
4+
5+
# Points to Metabase UI instance. "http://localhost:8095" value is only fitting for the local deployment. Make sure to set to the appropriate host name
6+
DRILL_UI_BASE_URL=http://localhost:8095
7+
8+
# PostgreSQL
9+
POSTGRES_HOST=postgres
10+
POSTGRES_DB=postgres
11+
POSTGRES_USER=postgres
12+
# make sure to use the strong password, the following value is added as an example
13+
POSTGRES_PASSWORD=mysecretpassword
14+
15+
# Metabase
16+
METABASE_POSTGRES_DB=db-metabase
17+
DRILL_METABASE_DASHBOARDS_VERSION=0.10.0

static/files/0.10.0/versions.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"applicationAgent": "0.10.0",
3+
"cicdPlugin": "0.10.0",
4+
"adminBackend": "0.10.0",
5+
"ui": "0.10.0",
6+
"metabaseDashboards": "0.10.0"
7+
}
File renamed without changes.

0 commit comments

Comments
 (0)