Fedora/CentOS/RHEL Installation

This guide will take you through step-by-step installation instructions for a CentOS box.

These directions should be relatively universal, but as RHEL/CentOS/Fedora are different operating systems, there might be slight differences.

Prerequisites

Beer Garden requires connectivity to a MongoDB server as well as a RabbitMQ installation. Please refer to their installation instructions for detailed installation instructions/configuration. Here, we will just go over the basics.

RabbitMQ

First, we need to install the rabbitmq-server and the plugins:

sudo yum install -y rabbitmq-server librabbitmq

Then we want to start the service:

Centos 6
sudo service rabbitmq-server start
Centos 7
sudo systemctl start rabbitmq-server

We also want to enable the management plugin. This isn’t strictly necessary but it makes managing RabbitMQ much easier.

sudo rabbitmq-plugins enable rabbitmq_management
You may see a problem after you do this where /etc/rabbitmq/enabled_plugins is not readable. If so, just do the following: chown rabbitmq.rabbitmq /etc/rabbitmq/enabled_plugins

Then restart:

Centos 6
sudo service rabbitmq-server restart
Centos 7
sudo systemctl restart rabbitmq-server

The management plugin starts a web interface on http://localhost:15672. You can visit that address in a browser to see the management plugin interface. The default username and password are both 'guest'.

The management interface is only bound to localhost, so you can only access it from the same machine that’s running RabbitMQ.

If you are planning on running these services long-term, you may want to make sure they stay on:

Centos 6
sudo chkconfig rabbitmq-server on
Centos 7
sudo systemctl enable rabbitmq-server

User Configuration

If you want remote plugins to be able to connect to your Rabbit queue you’ll need to use a different user (the default 'guest' user only allows connections from localhost). Add a new user like this:

# The USER and PASSWORD will be required for your beer-garden configuration
sudo rabbitmqctl add_user {USER} {PASSWORD}
sudo rabbitmqctl set_user_tags {USER} administrator
sudo rabbitmqctl set_permissions beer_garden ".*" ".*" ".*"

MongoDB

First we need to install the mongo packages:

sudo yum install -y mongodb-org
Don’t forget, beer-garden requires version 3.2 or higher.

Next, run the service:

Centos 6
sudo service mongod start
Centos 7
sudo systemctl restart mongod

Enable the service:

Centos 6
sudo chkconfig mongod on
Centos 7
sudo systemctl enable mongod

Nginx

First we need to install the nginx packages. Nginx is utilized for hosting ths Beer-Garden UI html. If there is already a service being hosted on Nginx you will want to backup your configurations before installing.

sudo yum install -y nginx

Next, run the service:

Centos 6
sudo service nginx start
Centos 7
sudo systemctl restart nginx

Installing Beer Garden

You’ll have to download our latest RPM from our GitHub releases section. Then install with yum:

sudo yum install beer-garden

All Beer Garden configuration files are located in /opt/beer-garden/conf. Feel free to adjust the configuration as necessary. For more information on configuration see Configuring Beer Garden.

Common Configuration Updates:

  1. RabbitMQ Username (mq.connection.admin.user, mq.connection.message.user)

  2. RabbitMQ Password (mq.connection.admin.password, mq.connection.message.password)

  3. Host names of Mongo and RabbitMQ if installed on different host (db.connection.host, mq.host)

Next we just need to start the service and make sure it’s running by default:

Centos 6
sudo service beer-garden start
sudo chkconfig beer-garden on
Centos 7
sudo systemctl enable beer-garden
sudo systemctl start beer-garden

Now check to see if it’s up: http://{host}:{port}/

Adding Local Plugins

Plugins come as .tar.gz files right now. So get access to the .tar.gz file and put it in the right spot:

cp /tmp/my-plugin-0.0.1.tar.gz /opt/beer-garden/plugins/.
cd /opt/beer-garden/plugins/
tar -zxvf my-plugin-0.0.1.tar.gz

Edit any configuration files necessary for the plugin. You can start the new plugin through the GUI:

  • Navigate to the beer-garden GUI

  • Select Admin → Systems

  • Click "Rescan Plugin Directory"

  • You should see your plugin appear!