Public | Automated Build

Last pushed: 2 years ago
Short Description
Publish/Subscribe Context Broker - Orion Context Broker (deprecated)
Full Description

Warning: This image has been deprecated and is no longer maintained.

Please use the official image available at https://hub.docker.com/r/fiware/orion/

Orion Context Broker Docker image

The Orion Context Broker is an implementation of the Publish/Subscribe Context Broker GE, providing the NGSI9 and NGSI10 interfaces.

Supported tags and respective Dockerfile links

Orion 0.23.0 image

Requirements

  • MongoDB. You can use the official images available at Docker Hub. This image has been tested with mongo:2.6 image.

Image Contents

  • [x] centos:centos6 baseimage available here
  • [x] Orion Context Broker (built from source)
  • [x] Running on port 1026

Usage

We strongly suggest you to use docker-compose. With docker compose you can define multiple containers in a single file, and link them easily.

So for this purpose, we have already a simple file that launches:

  • A MongoDB database
  • Data-only container for the MongoDB database
  • Orion Context Broker

The file orion.yml can be downloaded from here.

Once you get it, you just have to:

docker-compose -f orion.yml up -d

And all the services will be up. End to end testing can be done by doing:

curl <container-ip>:1026/version

What if I don't want to use docker-compose?

No problem, the only thing is that you will have to deploy a MongoDB yourself and specify the parameters.

An example of how to run it could be:

docker run -d --name <container-name> bitergia/fiware-orion:0.23.0 -fg

By running this, it expects a MongoDB database running on:

* MONGODB_HOSTNAME: `mongodb`
* MONGODB_PORT: `27017`
* ORION_PORT: `1026`

So if you have your MongoDB somewhere else, just attach it as a parameter like:

docker run -d --name <container-name> -e MONGODB_HOSTNAME=<mongodb-host> -e MONGODB_PORT=<mongodb-port> bitergia/fiware-orion:0.23.0 -fg

Any parameter added after bitergia/fiware-orion:0.23.0 is passed directly to orion. In the examples above, -fg tells orion not to detach itself as a daemon. This is needed if you want to keep the container running as docker stops the container when the PID 1 process inside the container exits.

If you want to run another command inside the container, just pass the command to run instead of the parameters to orion:

docker run -d --name <container-name> bitergia/fiware-orion:0.23.0 /bin/bash

Stopping the container

To stop the container, just use the docker stop <container-id> command. This will send the TERM signal to orion triggering a clean shutdown of the container.

Logs and other commands

By default, orion sends its output to stdout/stderr and this output can be viewed via the docker logs <container-id> command.

If you need to run another command in the same container, you can use the docker exec command.

Orion develop image

This image is the same as the 0.23.0 image but with orion compiled from HEAD of master branch.

Keeping the development tools

If you want to keep the development tools on the image, you can do so by modifying the following line on the Dockerfile:

ENV CLEAN_DEV_TOOLS 1

changing the value to 0:

ENV CLEAN_DEV_TOOLS 0

This will skip the cleaning process made at the end of the Dockerfile in order to thin the final image. This will grow the final image size from ~250 MB to ~1 GB. Then you can build the image by using the available Makefile by running:

make orion-develop

Orion 0.22.0 image

Find more information at Github

User feedback

Documentation

All the information regarding the image generation is hosted publicly on Github.

Issues

If you find any issue with this image, feel free to contact us via Github issue tracking system.

Docker Pull Command
Owner
bitergia
Source Repository