From 4884e2374cb1a5fa70c882cb985d2b53cb07e48e Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sat, 10 Jun 2017 23:50:59 +0200 Subject: Add gitlab-ci.yml --- .gitlab-ci.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .gitlab-ci.yml (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..42ee908 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,10 @@ +image: python:3.3 + +before_script: + - python3 -v + - which python + - pip3 install psycopg2 + +unittest: + script: + - python3 -m unittest discover tests -- cgit v1.2.3 From f78044bed6634ef016d6926d22c2395357fea01a Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sat, 10 Jun 2017 23:58:41 +0200 Subject: Add install stage to ci config --- .gitlab-ci.yml | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 42ee908..f5f84d6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,6 +5,14 @@ before_script: - which python - pip3 install psycopg2 +stages: + - unittest + - install + unittest: script: - python3 -m unittest discover tests + +install: + script: + - python3 setup.py install -- cgit v1.2.3 From f4ff6f18d8eae8247969ddc4c0fc63733c2a8fe3 Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sun, 11 Jun 2017 00:01:57 +0200 Subject: Lets try stages this way --- .gitlab-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f5f84d6..9750b1e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -7,12 +7,14 @@ before_script: stages: - unittest - - install + - integration unittest: + stage: test script: - python3 -m unittest discover tests install: + stage: integration script: - python3 setup.py install -- cgit v1.2.3 From 97fec750571abbc22cf3682952b4d6ed748fbff1 Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sun, 11 Jun 2017 00:03:04 +0200 Subject: Silly me, wrong stage defined --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9750b1e..2ccae85 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -10,7 +10,7 @@ stages: - integration unittest: - stage: test + stage: unittest script: - python3 -m unittest discover tests -- cgit v1.2.3 From 3f5936b94df8c8fd271b74c60a356491ab419c05 Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sun, 11 Jun 2017 00:08:58 +0200 Subject: Add a check for integration to print the version --- .gitlab-ci.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2ccae85..e18739b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,16 +5,11 @@ before_script: - which python - pip3 install psycopg2 -stages: - - unittest - - integration - unittest: - stage: unittest script: - python3 -m unittest discover tests install: - stage: integration script: - python3 setup.py install + - promtheus-pgbouncer-exporter --version -- cgit v1.2.3 From 3226f78614f875b8cf8897024e9a657556575325 Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sun, 11 Jun 2017 00:17:51 +0200 Subject: Use the right name for the executable --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e18739b..25eafaf 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,4 +12,4 @@ unittest: install: script: - python3 setup.py install - - promtheus-pgbouncer-exporter --version + - prometheus-pgbouncer-exporter --version -- cgit v1.2.3 From 0a626be4cdc8eee651c008724559f338d47347c4 Mon Sep 17 00:00:00 2001 From: Pablo Carranza Date: Sun, 11 Jun 2017 00:24:57 +0200 Subject: Finish adding installation dependencies --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.gitlab-ci.yml') diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 25eafaf..8ec7a11 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,4 +12,4 @@ unittest: install: script: - python3 setup.py install - - prometheus-pgbouncer-exporter --version + - /usr/local/bin/prometheus-pgbouncer-exporter --version -- cgit v1.2.3