-
-
Notifications
You must be signed in to change notification settings - Fork 716
Docker support
Josh Reichardt edited this page Oct 6, 2016
·
2 revisions
If you are interested in wrapping the dehyrdated script in a Docker container, you can use the following Dockerfile as a reference.
FROM alpine:latest
RUN apk add --update \
bash \
curl \
openssl \
&& rm -rf /var/cache/apk/*
WORKDIR dehydrated
COPY . .
ENTRYPOINT ["bash", "dehydrated"]
This builds a minimal Docker image (around 33mb) with all of the dependencies that dehyrdated needs to run and executes the script as an entrypoint.
To build this, make sure you are in the root directory of the dehydrated project, then run the following command:
docker build -t dehydrated .
To run the container, try the following command:
docker run -it --rm dehydrated
It should print out the default help message. If you want to write the certs onto the host use a volume mount, like this:
docker run -it --rm -v $(pwd):/dehydrated dehydrated