summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOleg Pykhalov <go.wigust@gmail.com>2021-04-23 18:19:15 +0300
committerOleg Pykhalov <go.wigust@gmail.com>2021-04-23 18:19:50 +0300
commitb8a8dcb9428c030179bbfccc877d92b93023e330 (patch)
tree80c3080b78668fc728ef5407afe8730f471bcba7
parentJenkinsfile: Comment Generate reports stage. (diff)
downloadansible-cmdb-majordomo-master.tar.gz
Jenkinsfile: Fix Generate reports.HEADmaster
-rw-r--r--Dockerfile3
-rw-r--r--Jenkinsfile24
2 files changed, 18 insertions, 9 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..da885b5
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,3 @@
+FROM python:3
+
+RUN pip install ansible-cmdb
diff --git a/Jenkinsfile b/Jenkinsfile
index d6b64ca..c3b3442 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -22,14 +22,20 @@ pipeline {
}
}
}
- // TODO: Fix Generate reports stage
- // stage("Generate reports") {
- // agent { label "guixsd" }
- // steps {
- // dir("/home/oleg/ansible-out") {
- // sh "env PATH=/home/oleg/bin:$PATH /home/oleg/.local/bin/ansible-cmdb -t html_fancy_split -p local_js=1 /home/oleg/ansible-out/out"
- // }
- // }
- // }
+ stage("Generate reports") {
+ agent { label "guixsd" }
+ steps {
+ sh(["docker", "run",
+ "--workdir", "/home/oleg/ansible-out",
+ "--network=host",
+ "--name", "ansible-cmdb",
+ "--rm",
+ "--volume", "/home/oleg/ansible-out:/home/oleg/ansible-out",
+ "ansible-cmdb",
+ "ansible-cmdb", "--template", "html_fancy_split",
+ "-p", "local_js=1",
+ "/home/oleg/ansible-out/out"].join(" "))
+ }
+ }
}
}