Manage Your Business with Compose, Odoo, and Bluemix


Odoo is a suite of applications to help you manage any business from anywhere. Learn how to deploy using Compose and IBM Bluemix so you'll have your own cloud of enterprise tools.

Marketing, sales pipelines, distribution, point-of-sale; sometimes it can be overwhelming trying to find the right tools to help you manage your business. Odoo, formerly called OpenERP, is an open source platform for building business applications that comes with a set of pre-built modules covering many business needs. You can enable only the modules you need and can extend the system by building your own modules, or by connecting to existing modules through an XML-RPC interface.

In this article, we'll introduce you to Odoo and show you how to deploy the Odoo stack on IBM Bluemix Container Service with Compose PostgreSQL providing the data layer.

Introduction to Odoo

Odoo is an open source ERP system, which is really a suite of tools to help you manage every facet of a business. Odoo allows you to install the tools they need right away while enabling you to expand as future needs arise.

Odoo applications also have the ability to coordinate with each other, so adding an invoice to a customer in the sales pipeline can be automatically added to sales reports.

Odoo also includes a surprisingly complete content management system. The templating system can access data models from other modules, making it useful for creating internal-facing team sites, and has an extensive palette of common page elements for creating customer-facing sites.

There are many more features, and the system is deeply customizable and extensible so it can fit the needs of many businesses. The best way to explore Odoo is to experiment with it, so let's get a copy running and try it out.

Installing Odoo

You can download and install Odoo for Windows and Linux using the installer for each, available on the Odoo website. Or, if you're more inclined to tinker with the inner workings of things, you can download the source code on Github and build Odoo manually.

However, the easiest way to get started is to deploy the official Docker container which contains the entire application pre-configured and ready to deploy. Configuration takes place through environment variables, which are set when we launch the container.

For this article, we'll use the Docker container and create a production-ready deployment. We'll back it with Compose PostgreSQL and host the Odoo application itself in the IBM Bluemix Container Service.

Create the Compose PostgreSQL Deployment

Odoo uses PostgreSQL to store your business data, and the default container needs to have access to the PostgreSQL deployment. By default, it is linked to Odoo as a service called db and which can be deployed along with Odoo using docker-compose.

Let's start with the data layer by spinning up a Compose PostgreSQL deployment. You can do so by creating a new database through the Compose UI or by creating a new deployment through the Compose API.

Once you have PostgreSQL set up, make sure you have your username and password available so we can configure the Odoo container with them; you can find them by clicking the reveal your credentials link on the overview page of your PostgreSQL deployment.

Deploy Odoo on Bluemix

Since we aren't modifying the original Docker image, we'll have Bluemix pull the Odoo container directly from Docker Hub. We'll also need to configure Odoo to use our Compose PosgreSQL deployment using the HOST environment variable, and set the USER and PASSWORD environment variables to those of our PostgreSQL deployment.

First things' first, let's spin up the Blumix Container Service. If you haven't already, you can check out the procedure to install the Bluemix CLI on the Bluemix Container Service docs page. Once you have the bx CLI tool installed and have logged in using bx login, you'll need to pull the Docker image from Docker Hub into your IBM Bluemix registry:

bx ic cpi odoo<your_namespace>/odoo

This will copy the image directly from Docker Hub and make it available in your Bluemix registry.

Once you have the container copied, creating a new container looks a lot like deploying a new container with Docker:

bx ic run -p 8069:8069 -e HOST=path_to_your_compose_postgresql -e USER=your_postgres_username -e PASSWORD=your_postgres_password<your_namespace>/odoo

Let's break this down:

If all goes well, you should see the container ID output to the console:


Use bx ic ps to see the status of your container:

CONTAINER ID        IMAGE                                                      COMMAND             CREATED             STATUS              PORTS               NAMES  
88ce0f99-e14   ""                  48 seconds ago      Building            8069/tcp            kickass_kilby  

Once the bx ic ps command shows a status of Running you are good to go.

CONTAINER ID        IMAGE                                                      COMMAND             CREATED             STATUS              PORTS               NAMES  
88ce0f99-e14   ""                  2 minutes ago       Running             8069/tcp            kickass_kilby  

To access the container on the Internet, we'll need to assign an IP address to it. You can see the available IP addresses using the following command:

$ bx ic ips
Number of allocated public IP addresses: 0

IP Address   Container ID  

If you don't have any available, use the following command to get one:

$ bx ic ip-request
IP address "" was obtained.  

Now that you have an IP address available, use the bind command to bind the IP address to your container.

$ bx ic ip-bind <your_ip> <your_container_id>
The IP address was bound successfully.  

You should now be able to access your Odoo installation from the following url:


Summing Things Up

Now that you've seen how to deploy Odoo with Bluemix and Compose, give it a test drive, explore the modules, and see what options are the best fit for your business. If you like what you see, you can continue to use it knowing that your sensitive business data is safe and secure.

If you have any feedback about this or any other Compose article, drop the Compose Articles team a line at We're happy to hear from you.


John O'Connor
John O'Connor is a code junky, educator, and amateur dad that loves letting the smoke out of gadgets, turning caffeine into code, and writing about it all. Love this article? Head over to John O'Connor’s author page to keep reading.

Conquer the Data Layer

Spend your time developing apps, not managing databases.