From 3b2f55dac386a7644a089ef45c7f960e18265983 Mon Sep 17 00:00:00 2001 From: Artem Nikitin Date: Tue, 23 Jul 2019 21:44:05 +0200 Subject: [PATCH] Fix docs build on PR job (#1351) * Fix docs build on PR job * Cleanup workspace before doing other steps --- build/ci/Makefile | 9 --------- build/ci/pr/Jenkinsfile | 12 ++++++++++-- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/build/ci/Makefile b/build/ci/Makefile index 6f11744754..e19dc9cd76 100644 --- a/build/ci/Makefile +++ b/build/ci/Makefile @@ -177,12 +177,3 @@ ci-gke-cleanup: ci-e2e-delete-cluster cloud-on-k8s-ci-e2e \ bash -c "GKE_CLUSTER_VERSION=1.11 $(GO_MOUNT_PATH)/operators/hack/gke-cluster.sh auth && \ $(GO_MOUNT_PATH)/build/ci/delete_unused_disks.py" - -# Run docs build -ci-build-docs: - @ docker run --rm -t \ - -v $(ROOT_DIR):$(GO_MOUNT_PATH) \ - docker.elastic.co/docs/build:1 \ - bash -c "git clone https://github.com/elastic/docs.git && \ - /docs/build_docs.pl --doc $(GO_MOUNT_PATH)/docs/index.asciidoc --out $(GO_MOUNT_PATH)/docs/html --chunk 1 && \ - test -e $(GO_MOUNT_PATH)/docs/html/index.html" diff --git a/build/ci/pr/Jenkinsfile b/build/ci/pr/Jenkinsfile index 83db69c11a..88f7c13d21 100644 --- a/build/ci/pr/Jenkinsfile +++ b/build/ci/pr/Jenkinsfile @@ -38,8 +38,16 @@ pipeline { } stage("Run docs build") { steps { - checkout scm - sh 'make -C build/ci ci-build-docs' + cleanWs() + sh 'git clone git@github.com:elastic/docs.git' + sh 'git clone git@github.com:elastic/cloud-on-k8s.git' + sh """ + $WORKSPACE/docs/build_docs \ + --doc $WORKSPACE/cloud-on-k8s/docs/index.asciidoc \ + --out $WORKSPACE/cloud-on-k8s/docs/html \ + --chunk 1 + """ + sh 'test -e $WORKSPACE/cloud-on-k8s/docs/html/index.html' } } stage("Run smoke E2E tests") {