Month: August 2015

We will install the most recent version of MongoDB from the 10gen repo. This requires us to first register the public key for the 10gen MongoDB apt repository, add the repository, and continue with the MongoDB installation.

Modify MongoDB settings
We need to modify our MongoDB configuration to set the bind address to ‘0.0.0.0’ and port to ‘27017’. By default these values should be correct, but we want to ensure these settings are configured explicitly.

sudo vim /etc/mongodb.conf

Ensure the following is set correctly (note this is only a portion of the configuration file):

# mongodb.conf

# Where to store the data.

# Note: if you run mongodb as a non-root user (recommended) you may
# need to create and set permissions for this directory manually,
# e.g., if the parent directory isn't mutable by the mongodb user.
dbpath=/var/lib/mongodb

#where to log
logpath=/var/log/mongodb/mongodb.log

logappend=true

port = 27017
bind_ip = 0.0.0.0

Restart the database
Now just restart the database for the changes to take effect.

When playing with vagrant, I set up a haproxy keepalived apache stack on ubuntu precise.
For that I forked this repository vagrant-haproxy-demo from github (https://github.com/justintime/vagrant-haproxy-demo.git) that run a haproxy standalone instance and I append my change to it to support keepalived.

First of all, I create the repository vagrant-haproxy-keepalived.
and I set remote origin to the repository created.
I create a new branch named development, I modify code and I do a commit.

Before this post I wrote and article on how to serve flask on ubuntu.
I share with you my first contact with vagrant, on a windows box I build a virtualbox vm that run nginx, and a flask “hello world” application.