1 .. This work is licensed under a
2 .. Creative Commons Attribution 4.0 International License.
3 .. http://creativecommons.org/licenses/by/4.0
7 Policy Docker Installation
8 --------------------------
14 Starting the ONAP Policy Framework Docker Images
15 ************************************************
16 In order to start the containers, you can use *docker-compose*. This uses the *docker-compose-all.yml* yaml file to bring up the ONAP Policy Framework. This file is located in the policy/docker repository. In the csit folder there are scripts to *automatically* bring up components in Docker, without the need to build all the images locally.
18 Clone the read-only version of policy/docker repo from gerrit:
22 git clone "https://gerrit.onap.org/r/policy/docker"
25 Start the containers automatically
26 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
28 .. note:: The start-all.sh script in policy/docker/csit will bring up all the Policy Framework components, and give the local ip for the GUI. The latest images will be downloaded from Nexus.
32 export CONTAINER_LOCATION=nexus3.onap.org:10001/
37 To stop them use ./stop-all.sh
44 Start the containers manually
45 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
47 **Step 1:** Set the containers location and project.
49 For *local* images, set CONTAINER_LOCATION="" (or don't set it at all)
50 *You will need to build locally all the images using the steps in the next chapter*
52 For *remote* images set CONTAINER_LOCATION="nexus3.onap.org:10001/"
56 export CONTAINER_LOCATION=nexus3.onap.org:10001/
60 **Step 2:** Set gerrit branch
62 Set GERRIT_BRANCH="master"
64 Or use the script get-branch.sh
68 source ./get-branch.sh
71 **Step 3:** Get all the images versions
73 Use the script get-versions.sh
77 source ./get-versions.sh
80 **Step 4:** Run the system using docker-compose
84 docker-compose -f docker-compose-all.yml up <image> <image>
87 **You now have a full standalone ONAP Policy framework up and running!**
90 Building the ONAP Policy Framework Docker Images
91 ************************************************
92 If you want to use your own local images, you can build them following these instructions:
94 **Step 1:** Build the Policy API Docker image
98 cd ~/git/onap/policy/api/packages
99 mvn clean install -P docker
101 **Step 2:** Build the Policy PAP Docker image
105 cd ~/git/onap/policy/pap/packages
106 mvn clean install -P docker
108 **Step 3:** Build the Drools PDP docker image.
110 This image is a standalone vanilla Drools engine, which does not contain any pre-built drools rules or applications.
114 cd ~/git/onap/policy/drools-pdp/
115 mvn clean install -P docker
117 **Step 4:** Build the Drools Application Control Loop image.
119 This image has the drools use case application and the supporting software built together with the Drools PDP engine. It is recommended to use this image if you are first working with ONAP Policy and wish to test or learn how the use cases work.
123 cd ~/git/onap/policy/drools-applications
124 mvn clean install -P docker
126 **Step 5:** Build the Apex PDP docker image:
130 cd ~/git/onap/policy/apex-pdp
131 mvn clean install -P docker
133 **Step 6:** Build the XACML PDP docker image:
137 cd ~/git/onap/policy/xacml-pdp/packages
138 mvn clean install -P docker
140 **Step 7:** Build the Policy SDC Distribution docker image:
144 cd ~/git/onap/policy/distribution/packages
145 mvn clean install -P docker