Dockerfile for PKI
This commit is contained in:
parent
8cab91f51a
commit
34f3747a3b
27
README.md
27
README.md
@ -140,6 +140,33 @@ docker rm db_setup
|
||||
docker run -d --name db --volumes-from mysql_data mysql
|
||||
```
|
||||
|
||||
4. Setup the PKI storages:
|
||||
|
||||
```
|
||||
docker run --name pki_storage -v /var/www/fic-server/PKI busybox
|
||||
docker run --name shared_storage -v /var/www/fic-server/shared busybox
|
||||
```
|
||||
|
||||
5. Build the PKI configuration container:
|
||||
|
||||
```
|
||||
docker build -t pki_setup pki/
|
||||
```
|
||||
|
||||
6. Configure the PKI
|
||||
|
||||
For development purpose, you can run the default setup:
|
||||
|
||||
```
|
||||
docker run --rm -it --volumes-from pki_storage --volumes-from shared_storage pki_setup
|
||||
```
|
||||
|
||||
For production environment:
|
||||
|
||||
```
|
||||
docker run --rm -it --volumes-from pki_storage --volumes-from shared_storage pki_setup /bin/bash
|
||||
TODO next steps
|
||||
```
|
||||
|
||||
|
||||
##### Requirements
|
||||
|
25
pki/Dockerfile
Normal file
25
pki/Dockerfile
Normal file
@ -0,0 +1,25 @@
|
||||
FROM debian:wheezy
|
||||
MAINTAINER Pierre-Olivier Mercier <nemunaire@nemunai.re>
|
||||
|
||||
# Install packages ####################################################
|
||||
|
||||
RUN apt-get -y update && \
|
||||
apt-get install -y \
|
||||
pwgen \
|
||||
openssl \
|
||||
&& \
|
||||
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
|
||||
# Copying files #######################################################
|
||||
|
||||
ADD CA.sh openssl.cnf /var/www/fic-server/pki/
|
||||
|
||||
# ENVIRONNEMENT #######################################################
|
||||
|
||||
VOLUME ["/var/www/fic-server/PKI"]
|
||||
|
||||
WORKDIR /var/www/fic-server/pki
|
||||
|
||||
CMD bash ./CA.sh -newca && \
|
||||
bash ./CA.sh -newserver && \
|
||||
bash ./CA.sh -gencrl
|
Loading…
Reference in New Issue
Block a user