Skip to content

Latest commit

 

History

History
93 lines (66 loc) · 2.13 KB

README.md

File metadata and controls

93 lines (66 loc) · 2.13 KB

cassandra Build Status

Docker image based on openjdk 8u171 (jre) alpine 3.8, Spring WebFlux and Achilles Embedded Cassandra Server

Status: in progress...

  • linux alpine 3.8
  • java version: openjdk 8u171 jre + jce policy
  • spring-boot / webflux version: 2.0.4.RELEASE
  • cassandra version: 3.11.2

Available tags:

Exposed ports:

  • 9042 - cassandra
  • 8080 - http (actuator) endpoints

Usage:

docker


docker run -p 8080:8080 -p 9042:9042 daggerok/cassandra

# shutdown cassandra:
curl http://localhost:8080/stop
# or:
http post :8080/cassandra/shutdown
# or press Ctrl+C

Dockerfile


FROM daggerok/cassandra
ENV HTTP_PORT=8080 \
    CASSANDRA_PORT=9042 \
    CASSANDRA_KEYSPACE='demo' \
    CASSANDRA_CLEAN_DATA_FILES_AT_STARTUP_ARG=true


docker build --no-cache -t my-cassandra .
docker run --rm --name=run-my-cassandra -p 8080:8080 -p 9042:9042 my-cassandra

docker-compose.yml


version: '2.1'
services:
  cassandra:
    image: daggerok/cassandra
    environment:
      HTTP_PORT: 8080
      CASSANDRA_PORT: 9042
      CASSANDRA_KEYSPACE: demo
      CASSANDRA_CLEAN_DATA_FILES_AT_STARTUP_ARG: true
    ports:
    - '8080:8080'
    - '9042:9042'
    volumes:
    - 'data:/home/cassandra'
    networks: [backing-services]
volumes:
  data: {}
networks:
  backing-services:
    driver: bridge


docker-compose up
# ...
docker-compose down -v

links: