drhank
v1.0.0
Published
Dr. Hank - offline Docker build and docker-compose auditor and fixer
Maintainers
Readme
Hank
Hank is an offline Docker build and docker-compose auditor and fixer.
It builds a ghost Docker image, analyzes your Dockerfile and compose config, detects common issues, and writes:
report.txt- build log and analysispatches.diff- suggested fixes.drhank.env.template- discovered env var keys to populate
Requirements
python3available on PATHPyYAMLinstalled in the Python environment used bypython3- Docker daemon available for
auditmode
Install via npm
npm install -g drhankThen from any project root:
drhank audit .
# or static checks only
drhank doctor .If you call just:
drhank .it behaves like:
drhank audit .Install via pip
pip install drhank
drhank audit .Typical workflow
Run Hank:
drhank audit .Inspect artifacts:
report.txtpatches.diff.drhank.env.template
Create and populate env file:
cp .drhank.env.template .drhank.env $EDITOR .drhank.envApply patches:
patch -p0 < patches.diffRebuild with your normal workflow:
docker compose up --build
Certificate handling
If Hank detects TLS or certificate problems in the build log, it will add:
volumes:
- ${HANK_CA_DIR:-./certs}:/usr/local/share/ca-certificates/drhank-ca:roPlace your corporate CA bundle or PEM files in ${HANK_CA_DIR} (default ./certs).
For build-time trust as well as runtime, extend your Dockerfile:
COPY certs /usr/local/share/ca-certificates/drhank-ca
RUN update-ca-certificates