Cleaning the ovsdb node completely for other test
[integration.git] / packaging / docker / README.md
1 # OpenDaylight Docker Image
2
3 The `Dockerfile` in this directory can be used to construct a Docker
4 image for the OpenDaylight SDN controller. The currently supported
5 OpenDaylight version is [Helium SR3][1]. Note that Helium uses Karaf
6 to install features, and that the Docker image doesn't install any
7 features by default. You'll need to choose which features to install
8 based on your use-case.
9
10 ## Pre-Built Docker Image
11
12 A pre-built OpenDaylight Helium SR3 image is [available on DockerHub][2].
13
14 ```
15 [~/sandbox]$ docker run -ti dfarrell07/odl:0.2.3 ./bin/karaf
16 # ODL's Docker image will be downloaded if needed
17 <snip>
18 opendaylight-user@root>
19 ```
20
21 ## Building ODL's Docker Image
22
23 To manually build a Docker image from the included `Dockerfile`:
24
25 ```
26 [~/integration/packaging/docker]$ docker build -t dfarrell07/odl:0.2.3 .
27 [~/integration/packaging/docker]$ docker images | grep odl
28 dfarrell07/odl    0.2.3    af863ac2de74    3 days ago    523.5 MB
29 ```
30
31 Replace the tag name with one of your own choosing.
32
33 ## Using the Image
34
35 To run commands against Dockerized OpenDaylight, use `docker run`. `WORKDIR`
36 is set to the root of ODL's install directory, `/opt/opendaylight`. Commands
37 passed to `docker run` should be relative to that path.
38
39 Additional information about running Docker images can be found [here][3].
40
41 ### Ports
42
43 The OpenDaylight Docker image opens the full set of ports known to be used
44 by OpenDaylight generally. For most real-world sets of installed Karaf
45 features, only a small subset of these ports will actually be used by
46 ODL.
47
48 * 162 - SNMP4SDN (only when started as root)
49 * 179 - BGP
50 * 1088 - JMX access
51 * 1790 - BGP/PCEP
52 * 1830 - Netconf
53 * 2400 - OSGi console
54 * 2550 - ODL Clustering
55 * 2551 - ODL Clustering
56 * 2552 - ODL Clustering
57 * 4189 - PCEP
58 * 4342 - Lisp Flow Mapping
59 * 5005 - JConsole
60 * 5666 - ODL Internal clustering RPC
61 * 6633 - OpenFlow
62 * 6640 - OVSDB
63 * 6653 - OpenFlow
64 * 7800 - ODL Clustering
65 * 8000 - Java debug access
66 * 8080 - OpenDaylight web portal
67 * 8101 - KarafSSH
68 * 8181 - MD-SAL RESTConf and DLUX
69 * 8383 - Netconf
70 * 12001 - ODL Clustering
71
72 By default ports will be mapped to random ports on the host system. The
73 mappings can be discovered using the `docker ps` command.
74
75 If you wish to map these ports to specific ports on the host system, use
76 the `-p <host-port>:<container-port>` flag with `docker run`. Note that
77 [container linking][4] is generally recommend over hard-wiring ports with
78 `-p`.
79
80
81 [1]: http://www.opendaylight.org/software/downloads/helium-sr3
82 [2]: https://registry.hub.docker.com/u/dfarrell07/odl/
83 [3]: https://docs.docker.com/reference/run/
84 [4]: https://docs.docker.com/userguide/dockerlinks/