New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mrit cass es docker compose #815

Merged
merged 3 commits into from Dec 1, 2017

Conversation

Projects
None yet
4 participants
@mritunjaykumar
Contributor

mritunjaykumar commented Dec 1, 2017

This PR contains a docker-compose file that helps in development process by running Cassandra and Elasticsearch as containers, and leave blueflood out of it. You can run or debug blueflood java code using IntelliJ and don't worry about Cassandra and Elasticsearch as they are taken care of by docker-compose file.
This will create two folders under your HOME directory cassdata (for persistence Cassandra data) and esdata (for persistence Elasticsearch data).

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Dec 1, 2017

Coverage Status

Coverage remained the same at 75.144% when pulling 20c566f on mrit-cass-es-docker-compose into 8472919 on master.

coveralls commented Dec 1, 2017

Coverage Status

Coverage remained the same at 75.144% when pulling 20c566f on mrit-cass-es-docker-compose into 8472919 on master.

@itzg

itzg approved these changes Dec 1, 2017

# Maps cassandra data to a local folder. This preserves data across
# container restarts. Note a folder 'cassdata' gets created locally in HOME directory.
volumes:
- ${HOME}/cassdata:/var/lib/cassandra

This comment has been minimized.

@itzg

itzg Dec 1, 2017

Collaborator

An alternative is to let docker-compose manage retaining the volumes (until you do a docker-compose down -v) and use a named volume like

    - cassdata:/var/lib/cassandra

and then further down in declare a volumes section:

volumes:
    cassdata:

No need to change what you have, because there are advantages to what you've specified. Just food for thought.

@itzg

itzg Dec 1, 2017

Collaborator

An alternative is to let docker-compose manage retaining the volumes (until you do a docker-compose down -v) and use a named volume like

    - cassdata:/var/lib/cassandra

and then further down in declare a volumes section:

volumes:
    cassdata:

No need to change what you have, because there are advantages to what you've specified. Just food for thought.

Show outdated Hide outdated contrib/blueflood-docker-compose/docker-compose-cass-es.yml Outdated
@itzg

itzg approved these changes Dec 1, 2017

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Dec 1, 2017

Coverage Status

Coverage decreased (-0.06%) to 75.084% when pulling fed388d on mrit-cass-es-docker-compose into 8472919 on master.

coveralls commented Dec 1, 2017

Coverage Status

Coverage decreased (-0.06%) to 75.084% when pulling fed388d on mrit-cass-es-docker-compose into 8472919 on master.

@mritunjaykumar mritunjaykumar merged commit 4848335 into master Dec 1, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@mritunjaykumar mritunjaykumar deleted the mrit-cass-es-docker-compose branch Dec 1, 2017

@izrik

This comment has been minimized.

Show comment
Hide comment
@izrik

izrik Dec 13, 2017

Member

@mritunjaykumar Why does it create folders in the user's home directory? Shouldn't it just keep all data in the container?

Member

izrik commented Dec 13, 2017

@mritunjaykumar Why does it create folders in the user's home directory? Shouldn't it just keep all data in the container?

@mritunjaykumar

This comment has been minimized.

Show comment
Hide comment
@mritunjaykumar

mritunjaykumar Dec 13, 2017

Contributor

@izrik - Folders are created in user's home directory to make sure data persists. Purpose of this docker-compose file is to help in development process when I would like to focus on the blueflood code and not worry about persisting data that I created during my earlier dev sessions.

Contributor

mritunjaykumar commented Dec 13, 2017

@izrik - Folders are created in user's home directory to make sure data persists. Purpose of this docker-compose file is to help in development process when I would like to focus on the blueflood code and not worry about persisting data that I created during my earlier dev sessions.

@itzg

This comment has been minimized.

Show comment
Hide comment
@itzg

itzg Dec 14, 2017

Collaborator

I know I'm beating a dead horse, but just wanted to point out that this confusion is alleviated by using named volumes rather than host mapped directories.

Collaborator

itzg commented Dec 14, 2017

I know I'm beating a dead horse, but just wanted to point out that this confusion is alleviated by using named volumes rather than host mapped directories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment