forked from cockroachdb/cockroach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
80036: docker: fix docker image to suit storage in memory r=ZhouXing19 a=ZhouXing19 Currently the datasets created in the init process are stored on disk, and they are inaccessible if the “real” server is started with storage in memory. This is because, for the container initialization, the current logic is: 1. start_init_server: start the single-node server in the background, with default on-disk storage setting; 2. run_init_queries: create default db and user, and run the init scripts saved in docker-entrypoint-initdb.d; 3. *stop the init server and restart the server* with given parameters in foreground. In this commit we start and keep running the init server with the given parameters, and eliminate the “stop and restart” step. Also, bring the server process from background to foreground with `fg` once all init queries are finished. Fixes cockroachdb#80005. Release note (docker): refactor the initialization process of the docker image to accomodate initialization scripts with memory storage. Co-authored-by: Jane Xing <[email protected]>
- Loading branch information
Showing
2 changed files
with
64 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters