blob: 9fe6fb14558372b47eb9b787e72aa2b47422b4a8 [file] [log] [blame]
Scott Baker58e88a82016-11-18 13:39:09 -08001# ONOS dockerfile with XOS/CORD additions
2
3FROM {{ onos_docker_image }}
4MAINTAINER Zack Williams <zdw@cs.arizona.edu>
5
6# Add SSL certs
Zack Williamsc047c872017-01-11 08:38:15 -07007COPY cord_root_ca.crt /usr/local/share/ca-certificates/cord_root_ca.crt
Zack Williamsc989f262017-05-11 13:02:59 -07008COPY cord_{{ site_name }}_im_ca.crt /usr/local/share/ca-certificates/cord_{{ site_name }}_im_ca.crt
Scott Baker58e88a82016-11-18 13:39:09 -08009RUN update-ca-certificates
10
11# Create Java KeyStore from certs
Zack Williamsc047c872017-01-11 08:38:15 -070012RUN openssl x509 -in /usr/local/share/ca-certificates/cord_root_ca.crt \
13 -outform der -out /usr/local/share/ca-certificates/cord_root_ca.der && \
Zack Williamsc989f262017-05-11 13:02:59 -070014 openssl x509 -in /usr/local/share/ca-certificates/cord_{{ site_name }}_im_ca.crt \
15 -outform der -out /usr/local/share/ca-certificates/cord_{{ site_name }}_im_ca.der && \
Zack Williamsc047c872017-01-11 08:38:15 -070016 keytool -import -noprompt -storepass {{ trust_store_pw }} -alias cord_root_ca \
17 -file /usr/local/share/ca-certificates/cord_root_ca.der \
18 -keystore /usr/local/share/ca-certificates/cord_ca_certs.jks && \
Zack Williamsc989f262017-05-11 13:02:59 -070019 keytool -import -noprompt -storepass {{ trust_store_pw }} -alias cord_{{ site_name }}_im_ca \
20 -file /usr/local/share/ca-certificates/cord_{{ site_name }}_im_ca.der \
Zack Williamsc047c872017-01-11 08:38:15 -070021 -keystore /usr/local/share/ca-certificates/cord_ca_certs.jks
Scott Baker58e88a82016-11-18 13:39:09 -080022
Jonathan Hart75ac6e92017-07-25 11:23:08 -070023# Let ONOS know where the keystore is
24ENV JAVA_OPTS="-Djavax.net.ssl.trustStore=/usr/local/share/ca-certificates/cord_ca_certs.jks -Djavax.net.ssl.trustStorePassword={{ trust_store_pw }}"
Scott Baker58e88a82016-11-18 13:39:09 -080025
Zack Williams30c01f92017-02-19 23:38:52 -070026# Configure ONOS to log with log4j to ElasticStack
27COPY org.ops4j.pax.logging.cfg /root/onos/apache-karaf-3.0.5/etc/org.ops4j.pax.logging.cfg
28