aboutsummaryrefslogtreecommitdiffstats
path: root/build/test
diff options
context:
space:
mode:
authorKristian Lyngstol <kristian@bohemians.org>2016-04-13 21:17:28 +0200
committerKristian Lyngstol <kristian@bohemians.org>2016-04-13 21:17:28 +0200
commita09b4d33818f1b3fd3836a99cbb742fa84caecb4 (patch)
tree336fbdff24655ff4079d1971b347935aa3714766 /build/test
parente8a20f730651d07deff33dc559acfdca32cce271 (diff)
Working test! It's amazing!
Never been so happy to see a single switch in the nms. Missing: Varnish and collectors and better deplist. Also: this is mainly _test_ stuff, not meant for development OR production.
Diffstat (limited to 'build/test')
-rw-r--r--build/test/db-test.Dockerfile1
-rw-r--r--build/test/playbook-test.yml16
2 files changed, 16 insertions, 1 deletions
diff --git a/build/test/db-test.Dockerfile b/build/test/db-test.Dockerfile
index cd6161e..a182040 100644
--- a/build/test/db-test.Dockerfile
+++ b/build/test/db-test.Dockerfile
@@ -5,5 +5,6 @@ RUN cat /pg_hba.tail >> /etc/postgresql/9.4/main/pg_hba.conf
RUN service postgresql start && su postgres -c "psql --command=\"CREATE ROLE nms PASSWORD 'risbrod' NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT LOGIN;\"" && su postgres -c "createdb -O nms nms" && service postgresql stop
ADD schema.sql /schema.sql
RUN service postgresql start && su postgres -c "cat /schema.sql | psql nms" && service postgresql stop
+RUN echo "listen_addresses = '*'" >> /etc/postgresql/9.4/main/postgresql.conf
CMD pg_ctlcluster --foreground 9.4 main start
EXPOSE 5432
diff --git a/build/test/playbook-test.yml b/build/test/playbook-test.yml
index 2794b21..4a04328 100644
--- a/build/test/playbook-test.yml
+++ b/build/test/playbook-test.yml
@@ -4,6 +4,7 @@
tasks:
- name: make db-test
docker_image:
+ nocache: true
state: build
name: nms-db-test
docker_api_version: 1.18
@@ -11,6 +12,7 @@
path: "src/tgnms/build/"
- name: make front-test
docker_image:
+ nocache: true
state: build
name: nms-front-test
docker_api_version: 1.18
@@ -23,6 +25,18 @@
docker_api_version: 1.18
dockerfile: test/collector-test.Dockerfile
path: "src/tgnms/build/"
+ - name: stop db
+ docker:
+ name: nms-db
+ state: stopped
+ image: nms-db-test
+ docker_api_version: 1.18
+ - name: stop front
+ docker:
+ name: nms-front
+ state: stopped
+ image: nms-front-test
+ docker_api_version: 1.18
- name: start db
docker:
name: nms-db
@@ -36,7 +50,7 @@
name: nms-front
image: nms-front-test
docker_api_version: 1.18
- state: reloaded
+ state: started
net: bridge
links:
- "nms-db:db"