Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 1 | # Base ubuntu with added packages needed for open ecomp |
Timoney, Dan (dt5972) | 6f0c010 | 2018-06-18 23:01:08 -0400 | [diff] [blame] | 2 | FROM onap/ccsdk-odl-oxygen-image:${project.version} |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 3 | MAINTAINER CCSDK Team (onap-ccsdk@lists.onap.org) |
Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 4 | ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64 |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 5 | ENV ODL_HOME /opt/opendaylight |
Timoney, Dan (dt5972) | 21821db | 2018-03-13 19:26:40 -0400 | [diff] [blame] | 6 | ENV SDNC_CONFIG_DIR /opt/onap/ccsdk/data/properties |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 7 | ENV CCSDK_SLI_CORE_REPO mvn:org.onap.ccsdk.sli.core/ccsdk-sli-core-all/${ccsdk.sli.core.version}/xml/features |
| 8 | ENV CCSDK_SLI_ADAPTORS_REPO mvn:org.onap.ccsdk.sli.adaptors/ccsdk-sli-adaptors-all/${ccsdk.sli.adaptors.version}/xml/features |
| 9 | ENV CCSDK_SLI_NORTHBOUND_REPO mvn:org.onap.ccsdk.sli.northbound/ccsdk-sli-northbound-all/${ccsdk.sli.northbound.version}/xml/features |
| 10 | ENV CCSDK_SLI_PLUGINS_REPO mvn:org.onap.ccsdk.sli.plugins/ccsdk-sli-plugins-all/${ccsdk.sli.plugins.version}/xml/features |
Timoney, Dan (dt5972) | be94cc1 | 2018-07-02 18:02:35 -0400 | [diff] [blame^] | 11 | ENV ANSIBLE_GPG_KEY ${ansible.gpg.key} |
| 12 | |
Dan Timoney | 74e4e8d | 2017-08-22 11:51:54 -0400 | [diff] [blame] | 13 | # copy the opendaylight credentials |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 14 | COPY idmlight.db.mv.db $ODL_HOME/data |
| 15 | |
| 16 | |
| 17 | # copy CCSDK mvn artifacts to ODL repository |
| 18 | COPY system /tmp/system |
| 19 | RUN rsync -a /tmp/system $ODL_HOME && rm -rf /tmp/system |
| 20 | |
| 21 | # Add CCSDK repositories to boot repositories |
| 22 | RUN cp $ODL_HOME/etc/org.apache.karaf.features.cfg $ODL_HOME/etc/org.apache.karaf.features.cfg.orig |
| 23 | RUN cat $ODL_HOME/etc/org.apache.karaf.features.cfg.orig | sed -e "\|featuresRepositories|s|$|, ${CCSDK_SLI_CORE_REPO}, ${CCSDK_SLI_ADAPTORS_REPO}, ${CCSDK_SLI_NORTHBOUND_REPO}, ${CCSDK_SLI_PLUGINS_REPO}|" > $ODL_HOME/etc/org.apache.karaf.features.cfg |
| 24 | |
| 25 | # Create odl user |
| 26 | RUN useradd odl |
| 27 | |
Timoney, Dan (dt5972) | be94cc1 | 2018-07-02 18:02:35 -0400 | [diff] [blame^] | 28 | # Install ansible |
| 29 | COPY ansible-sources.list /etc/apt/sources.list.d |
| 30 | RUN gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv ${ANSIBLE_GPG_KEY} && \ |
| 31 | gpg --export --armor ${ANSIBLE_GPG_KEY} | apt-key add - && \ |
| 32 | apt-get update && \ |
| 33 | apt-get install -y ansible |
| 34 | |
| 35 | # Install ansible-opendaylight |
| 36 | RUN ansible-galaxy install git+https://git.opendaylight.org/gerrit/integration/packaging/ansible-opendaylight |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 37 | |
| 38 | # Copy ccsdk install playbook |
| 39 | COPY install_ccsdk.yml /tmp |
| 40 | |
| 41 | # Install features in ODL |
| 42 | RUN ansible-playbook -i "localhost," -c local /tmp/install_ccsdk.yml |
| 43 | |
Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 44 | |
Dan Timoney | 74e4e8d | 2017-08-22 11:51:54 -0400 | [diff] [blame] | 45 | # copy deliverables to opt |
Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 46 | COPY opt /opt |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 47 | COPY org.ops4j.pax.logging.cfg /opt/opendaylight/etc/org.ops4j.pax.logging.cfg |
Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 48 | |
Marcus G K Williams | dc299ed | 2017-09-14 15:15:45 -0700 | [diff] [blame] | 49 | |
Timoney, Dan (dt5972) | e14a020 | 2018-06-22 17:05:16 -0400 | [diff] [blame] | 50 | ENTRYPOINT /opt/onap/ccsdk/bin/startODL.sh |
Dan Timoney | 471dafa | 2017-08-21 14:44:05 -0400 | [diff] [blame] | 51 | EXPOSE 8181 |