Skip to content

Commit fc0c7b4

Browse files
authored
add support for tidb with nightly images (#16)
1 parent 9f06bc7 commit fc0c7b4

File tree

4 files changed

+39
-1
lines changed

4 files changed

+39
-1
lines changed

config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"dbms_list": ["mysql", "postgres", "sqlite"],
2+
"dbms_list": ["mysql", "postgres", "sqlite", "tidb"],
33
"dbms": "mysql",
44
"container_name": "mysql-custom",
55
"image": "mysql-custom",

tidb/Dockerfile

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
2+
FROM golang:1.23 AS builder
3+
4+
ARG TIDB_VERSION=master
5+
ENV TIDB_VERSION=${TIDB_VERSION}
6+
7+
WORKDIR /go/src/github.com/pingcap
8+
9+
10+
RUN git clone --depth=1 --branch=${TIDB_VERSION} https://github.com/pingcap/tidb.git
11+
12+
WORKDIR /go/src/github.com/pingcap/tidb
13+
14+
15+
RUN make
16+
17+
18+
FROM debian:bookworm-slim
19+
20+
WORKDIR /tidb
21+
COPY --from=builder /go/src/github.com/pingcap/tidb/bin/tidb-server .
22+
23+
EXPOSE 4000
24+
ENTRYPOINT ["./tidb-server"]
25+

tidb/__init__.py

Whitespace-only changes.

tidb/config.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"embedded": "no",
3+
"dbms": "tidb",
4+
"image": "pingcap/tidb:nightly",
5+
"container_name": "tidb-sqlancer",
6+
"port": 4000,
7+
"username": "root",
8+
"password": "",
9+
"oracle": "WHERE",
10+
"num_threads": 4,
11+
"timeout_seconds": 60
12+
}
13+

0 commit comments

Comments
 (0)