-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
32 lines (24 loc) · 851 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
FROM alpine:latest
MAINTAINER unoexperto <[email protected]>
# python is necessary for ssdb-cli
RUN apk update && \
apk add gcc python && \
apk add --virtual .build-deps autoconf make g++ git
RUN mkdir -p /usr/src/ssdb
RUN git clone --depth 1 https://github.com/ideawu/ssdb.git /usr/src/ssdb && \
make -C /usr/src/ssdb && \
make -C /usr/src/ssdb install && \
rm -rf /usr/src/ssdb
RUN apk del .build-deps
RUN sed \
-e 's@ip:.*@ip: 0.0.0.0@' \
-e 's@cache_size:.*@cache_size: 4096@' \
-e 's@write_buffer_size:.*@write_buffer_size: 512@' \
-e 's@level:.*@level: info@' \
-e 's@output:.*@output:@' \
-i /usr/local/ssdb/ssdb.conf
EXPOSE 8888
VOLUME /usr/local/ssdb/var/data
VOLUME /usr/local/ssdb/var/meta
WORKDIR /usr/local/ssdb/
CMD ["/usr/local/ssdb/ssdb-server", "/usr/local/ssdb/ssdb.conf"]