Skip to content
Permalink
Browse files

* Added Docker image (#249)

  • Loading branch information...
adamansky committed Jun 11, 2019
1 parent 42c0842 commit b30191f1d890f346aea3948463055998f06603e5
Showing with 57 additions and 0 deletions.
  1. +1 −0 Changelog
  2. +17 −0 README.md
  3. +22 −0 docker/Dockerfile
  4. +15 −0 docker/README.md
  5. +2 −0 release.sh
@@ -1,5 +1,6 @@
ejdb2 (2.0.18) UNRELEASED; urgency=medium

* Added Docker image (#249)
* Better qsort_t detection, build ok with `musl`

-- Anton Adamansky <adamansky@gmail.com> Wed, 12 Jun 2019 00:49:49 +0700
@@ -920,6 +920,23 @@ Note: If `collection` is not found no errors will be reported.
# Docker support
If you have [Docker]("https://www.docker.com/") installed, you can build a Docker image and run it in a container
```
cd docker
docker build -t ejdb2 .
docker run -d -p 9191:9191 --name myEJDB ejdb2 --access myAccessKey
```
or get an image of `ejdb2` directly from the Docker Hub
```
docker run -d -p 9191:9191 --name myEJDB softmotions/ejdb2 --access myAccessKey
```
# C API
EJDB can be empdedded into any `C/C++` application.
@@ -0,0 +1,22 @@
FROM alpine:3.9

MAINTAINER Anton Adamansky <adamansky@gmail.com>

RUN apk add --no-cache cmake gcc binutils libc-dev git ninja

RUN git clone https://github.com/Softmotions/ejdb.git && \
mkdir -p ejdb/build

WORKDIR ejdb/build

RUN cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/opt/ejdb2 && \
ninja install && \
mkdir -p /ejdb2_data

VOLUME ["/ejdb2_data"]

EXPOSE 9191

WORKDIR /ejdb2_data

ENTRYPOINT ["/opt/ejdb2/bin/jbs", "-b", "0.0.0.0"]
@@ -0,0 +1,15 @@
# Docker support

If you have [Docker]("https://www.docker.com/") installed, you can build a Docker image and run it in a container

```
cd docker
docker build -t ejdb2 .
docker run -d -p 9191:9191 --name myEJDB ejdb2 --access myAccessKey
```

or get an image of `ejdb2` directly from the Docker Hub

```
docker run -d -p 9191:9191 --name myEJDB softmotions/ejdb2 --access myAccessKey
```
@@ -15,6 +15,8 @@ readme() {
echo -e "\n\n" >> "./README.md"
cat "./src/jbr/README.md" >> "./README.md"
echo -e "\n\n" >> "./README.md"
cat "./docker/README.md" >> "./README.md"
echo -e "\n\n" >> "./README.md"
cat "./CAPI.md" >> "./README.md"
echo -e '\n# License\n```\n' >> "./README.md"
cat "./LICENSE" >> "./README.md"

0 comments on commit b30191f

Please sign in to comment.
You can’t perform that action at this time.