Add Docker user management scripts and some setup automation#21
Merged
Add Docker user management scripts and some setup automation#21
Conversation
Add scripts to create pre-verified user accounts in Datomic without requiring SMTP/email verification, plus an automated setup script that generates secure passwords, SSL certificates, and .env configuration. - docker-setup.sh: interactive/auto setup (passwords, SSL, directories) - docker-user.sh: create, verify, check, list, batch user operations - docker/scripts/manage-user.clj: Clojure script running inside container - Docker Compose: .env interpolation, native healthchecks, service_healthy deps - CI workflow for Docker integration testing - Documentation and README quick-start guide
Cover two previously untested paths: - docker-user.sh init (creates admin from .env INIT_ADMIN_* vars) - docker-setup.sh --auto --force (regenerates .env with consistent passwords)
00f4309 to
dcf8227
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
docker-user.sh— shell wrapper to create, verify, check, list, and batch-create pre-verified user accounts directly in Datomic, bypassing email verification entirely. Auto-detects the running container and waits for healthcheck before executing.docker-setup.sh— interactive/non-interactive setup script that generates secure random passwords, a.envfile, self-signed SSL certs, and required directories in one step.docker/scripts/manage-user.clj— Clojure script that runs inside the orcpub container using the uberjar classpath (datomic.api+buddy.hashers). Supportscreate,batch,verify,check, andlistcommands.docker-compose.yamlanddocker-compose-build.yamlnow use.envinterpolation (no more editing passwords in YAML), native healthchecks, andcondition: service_healthydependencies.Why
Self-hosted Docker deployments had no way to create usable accounts without a working SMTP server. Users had to either configure email or manually poke the database. This gives them a one-liner:
./docker-user.sh create admin admin@example.com MyPass123.What changed
docker-user.shdocker-setup.shdocker/scripts/manage-user.cljdocker/scripts/users.example.txt.env.exampledocker-compose.yamldocker-compose-build.yamldocs/docker-user-management.mdREADME.md.github/workflows/docker-integration.yml.gitignore.claude-data/Test plan
./docker-setup.sh --autogenerates valid .env on clean checkout./docker-user.sh createworks against running stack