Skip to content

Commit 50b6544

Browse files
author
Ben Miller
committed
add docker configs to spin up zenoss 3.2 and 4.2
1 parent a8e536a commit 50b6544

7 files changed

Lines changed: 45 additions & 0 deletions

File tree

README.textile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,8 @@ of course grow over time):
8080

8181
If you get any failures, you should of course address them
8282

83+
Since the test suite requires a working Zenoss installation to test against,
84+
some docker files are provided under test/docker. From a docker host, clone this
85+
repo, cd to the appropriate test/docker/ subdirectory, and run @sh start.sh@ to
86+
build and start the container. Once the container is running, you should be able
87+
to run the tests as described above.

test/docker/3.2.1/Dockerfile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
FROM centos:5
2+
RUN mkdir /opt/zenoss
3+
WORKDIR /opt/zenoss
4+
RUN yum -y install mysql-server net-snmp net-snmp-utils gmp \
5+
libgomp libgcj liberation-fonts libaio wget
6+
RUN wget http://downloads.sourceforge.net/project/zenoss/zenoss-3.2/zenoss-3.2.1/zenoss-3.2.1.el5.x86_64.rpm
7+
RUN service mysqld start && mysqladmin -u root password '' && \
8+
mysqladmin -u root -h localhost password ''
9+
RUN rpm -ivh ./zenoss-3.2.1.el5.x86_64.rpm
10+
RUN service zenoss start
11+
ADD remote_start.sh ./

test/docker/3.2.1/remote_start.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
service mysqld start
2+
service zenoss start
3+
tail -F /opt/zenoss/log/event.log

test/docker/3.2.1/start.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
docker build -t zen3.2.1 .
2+
docker run -i -p 8080:8080 -t zen3.2.1 sh remote_start.sh

test/docker/4.2.5/Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
FROM centos:6
2+
RUN mkdir /opt/zenoss
3+
WORKDIR /opt/zenoss
4+
RUN yum -y install wget which
5+
ADD https://raw.githubusercontent.com/zenoss/core-autodeploy/4.2.5/core-autodeploy.sh ./
6+
ADD https://raw.githubusercontent.com/zenoss/core-autodeploy/4.2.5/secure_zenoss.sh ./
7+
ADD https://raw.githubusercontent.com/zenoss/core-autodeploy/4.2.5/zenpack_actions.txt ./
8+
RUN chmod +x ./core-autodeploy.sh
9+
RUN echo -e "\ny\n" | ./core-autodeploy.sh
10+
ADD remote_start.sh ./

test/docker/4.2.5/remote_start.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/sh
2+
service zenoss start &
3+
service mysql start &
4+
service rabbitmq-server start
5+
rabbitmqctl stop_app
6+
rabbitmqctl reset
7+
rabbitmqctl start_app
8+
rabbitmqctl add_vhost "/zenoss"
9+
rabbitmqctl add_user zenoss \
10+
"$(sed -n 's/amqppassword \(.*\)/\1/p' /opt/zenoss/etc/global.conf)"
11+
rabbitmqctl set_permissions -p "/zenoss" zenoss ".*" ".*" ".*"
12+
tail -F /opt/zenoss/log/event.log

test/docker/4.2.5/start.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
docker build -t zen4.2.5 .
2+
docker run -i -p 8080:8080 -t zen4.2.5 sh remote_start.sh

0 commit comments

Comments
 (0)