Skip to content

Setting up OpenDF using Docker

Pasindu Perera edited this page Mar 4, 2017 · 7 revisions

Requirements:

  1. Docker installed on your PC. Use the following guide to install: Docker-Installation

  2. OpenDF cloned onto your PC. Get OpenDF from here: OpenDF

Steps:

  1. First, you'll need to build the image.

cd to the OpenDF directory and run:

sudo docker build -t my_opendf .

if this command gives an error

"docker build" requires exactly 1 argument(s).

See 'docker build --help'.

Usage: docker build [OPTIONS] PATH | URL | -

Build an image from a Dockerfile

try

sudo docker build -t my_opendf ./

  1. We'll need a container with an OpenDF instance running inside it. Use command:

sudo docker run --name my_first_odf_instance -i -t my_opendf

That'll set up OpenDF in the container created by docker.

Note: In order to use OpenDF properly, you'd require your user inserted into the SQL database. In that case, read the following steps:

  1. Enter MySQL by typing:
    mysql -u root -p

  2. The password should be 'rooot'. If not, watch for two lines starting with "[INFO]" a bit further up at the end of the installation output. There you'll find the password. (This is a new feature which isn't part of the main OpenDF installation yet, but may be someday)

  3. Then execute: insert into User( username, password, email, name, level) values('_username_', '_password_', '[email protected]', 'name', '12345678910'); put anything into the fields.

That should setup OpenDF successfully.