Skip to content
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

Initialization script #31

Closed
AnderUstarroz opened this issue Oct 30, 2015 · 4 comments
Closed

Initialization script #31

AnderUstarroz opened this issue Oct 30, 2015 · 4 comments
Labels
Request Request for image modification or feature

Comments

@AnderUstarroz
Copy link

This is a feature request,
Some docker images like the official postgres allow initialization scrips during execution. Just adding some SQL or Shell files to the folder /docker-entrypoint-initdb.d and docker will execute all these scripts after building the image, so we are able to create schemes, add initial data ETC... I believe this is a great feature and wouldn't be really hard to add to cassandra, just take a look at postgres entry-point.sh .

@yosifkit
Copy link
Member

yosifkit commented Nov 3, 2015

This one feels a bit more complicated than Mysql/Postgres. The other images start the sql server with a limited listening state, ie only localhost or unix domain socket, in order to complete sql imports and scripts before stopping the server and starting it again as pid 1 with normal network access. It would be a fairly major change to the current script to prepare the server with localhost listen and broadcast addresses, and to only do so if this is the first server, ie no CASSANDRA_SEEDS.

If this is something that is commonly wanted, I would not be opposed to a PR.

@slafs
Copy link

slafs commented Nov 18, 2015

Would love to see that also. Any suggestions about a workaround on this?

@wglambert wglambert added the Request Request for image modification or feature label Apr 24, 2018
@tianon tianon mentioned this issue Sep 20, 2018
@tianon
Copy link
Member

tianon commented Sep 20, 2018

There are a couple workarounds discussed over in #65 if you have an oversimplified deployment.

@tianon
Copy link
Member

tianon commented Oct 3, 2018

Closing with a similar rationale to #94 -- the proper deployment of Cassandra is clustered, and is much more complicated to get right automatically. It is not recommended to use a standalone deployment, and I fear such a feature would encourage folks to do so (since it couldn't possibly work with a cluster properly and/or detect clustered operation). For folks that really want to go there, building something like that on top of the provided image shouldn't be too much work. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Request Request for image modification or feature
Projects
None yet
Development

No branches or pull requests

5 participants