-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
24 additions
and
24 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,27 +68,22 @@ RUN git clone https://github.com/vsoch/pydicom | |
WORKDIR pydicom | ||
RUN python setup.py install | ||
|
||
RUN mkdir /code | ||
RUN mkdir -p /var/www/images | ||
RUN mkdir /data | ||
WORKDIR /code | ||
RUN /usr/bin/yes | pip uninstall cython | ||
RUN apt-get remove -y gfortran | ||
|
||
# This is needed for certificate on server, interactive run for now | ||
# http://www.zoharbabin.com/install-ssl-on-ubuntu-and-enable-https/ | ||
WORKDIR /tmp | ||
RUN openssl genrsa -out server.key 4096 && mv server.key /etc/ssl/certs | ||
RUN openssl dhparam -out dhparam.pem 4096 && mv dhparam.pem /etc/ssl/certs | ||
RUN cat > csr_details.txt <<-EOF | ||
[req] | ||
default_bits = 2048 | ||
prompt = no | ||
default_md = sha256 | ||
distinguished_name = dn | ||
|
||
[ dn ] | ||
C=US | ||
ST=California | ||
L=San Mateo County | ||
O=End Point | ||
OU=Sendit | ||
[email protected] | ||
CN = cci-docker-webapp-p03 | ||
EOF | ||
|
||
RUN cp /code/csr_details.txt /tmp | ||
WORKDIR /tmp | ||
RUN echo CN = \"`hostname`\" >> csr_details.txt | ||
|
||
# call openssl now by piping the newly created file in | ||
RUN openssl req -new -sha256 -nodes -out server.csr -newkey rsa:2048 -keyout server.key -config <( cat csr_details.txt ) | ||
|
@@ -98,18 +93,11 @@ RUN cp server.key /etc/ssl/private | |
RUN cp server.crt /etc/ssl/certs | ||
|
||
# Reinstall root certificates | ||
RUN apt-get install --reinstall ca-certificates | ||
RUN apt-get install -y ca-certificates | ||
RUN mkdir /usr/local/share/ca-certificates/cacert.org | ||
RUN wget -P /usr/local/share/ca-certificates/cacert.org http://www.cacert.org/certs/root.crt http://www.cacert.org/certs/class3.crt | ||
RUN update-ca-certificates | ||
|
||
RUN mkdir /code | ||
RUN mkdir -p /var/www/images | ||
RUN mkdir /data | ||
WORKDIR /code | ||
RUN /usr/bin/yes | pip uninstall cython | ||
RUN apt-get remove -y gfortran | ||
|
||
RUN apt-get autoremove -y | ||
RUN apt-get clean | ||
RUN rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[req] | ||
default_bits = 2048 | ||
prompt = no | ||
default_md = sha256 | ||
distinguished_name = dn | ||
|
||
[ dn ] | ||
C=US | ||
ST=California | ||
L=San Mateo County | ||
O=End Point | ||
OU=Sendit |