SimpleCA is mainly designed to generate valid server certificates for internal purpose.
First create a docker volume to save the key and the certificate of the Certificate Authority.
docker volume create ca
Then start your own Certificate Authority
docker run --detach --name simpleca --volume ca:/ca --publish 80 cyd01/simpleca:latest
At first start a valid key and certificate is created (without volume there will be recreated each time the container restart).
Now the Certificate Authority is reachable at local 80 port. To get the CA certificate run
curl -s http://localhost/ca/ca.crt
To get more informations on how to use SimpleCA jump to https://simpleca.piratemind.com.
You can use your own key and certificate of the Certificate Authority. In the container the names must be ca.key and ca.crt. You just have to copy them into the container.
docker cp pathtoyour.key simpleca:/ca/ca.key
docker cp pathtoyour.cert simpleca:/ca/ca.crt
Some certificate creation parameters can be over defined at startup by passing an environment variable:
| Name | Default | Description |
|---|---|---|
NBDAYS | 90 | the number of days certificate validity |
SIZE | 2048 | the private key size |
ISSUER_CERT_URL | N/A | URL of the issuer certificate |
C | FR | the certificate country |
ST | France | the certificate state |
L | Paris | the certificate location |
O | Orga | the certificate organization |
OU | Unit | the certificate organization unit |
Ex: start the SimpleCA certificate authority with one month certificate validity only:
docker run --detach --name simpleca --volume ca:/ca --publish 80 --env NBDAYS=31 cyd01/simpleca:latest
Content type
Image
Digest
sha256:4b89bb68b…
Size
76.6 MB
Last updated
4 days ago
docker pull cyd01/simpleca