Skip to content

Commit 4e1fd7f

Browse files
authored
Fix docs build on PR job (#1352)
* Fix docs build on PR job * Cleanup workspace before doing other steps
1 parent 41b8ad1 commit 4e1fd7f

File tree

2 files changed

+10
-11
lines changed

2 files changed

+10
-11
lines changed

build/ci/Makefile

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -177,12 +177,3 @@ ci-gke-cleanup: ci-e2e-delete-cluster
177177
cloud-on-k8s-ci-e2e \
178178
bash -c "GKE_CLUSTER_VERSION=1.11 $(GO_MOUNT_PATH)/operators/hack/gke-cluster.sh auth && \
179179
$(GO_MOUNT_PATH)/build/ci/delete_unused_disks.py"
180-
181-
# Run docs build
182-
ci-build-docs:
183-
@ docker run --rm -t \
184-
-v $(ROOT_DIR):$(GO_MOUNT_PATH) \
185-
docker.elastic.co/docs/build:1 \
186-
bash -c "git clone https://github.com/elastic/docs.git && \
187-
/docs/build_docs.pl --doc $(GO_MOUNT_PATH)/docs/index.asciidoc --out $(GO_MOUNT_PATH)/docs/html --chunk 1 && \
188-
test -e $(GO_MOUNT_PATH)/docs/html/index.html"

build/ci/pr/Jenkinsfile

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,16 @@ pipeline {
3838
}
3939
stage("Run docs build") {
4040
steps {
41-
checkout scm
42-
sh 'make -C build/ci ci-build-docs'
41+
cleanWs()
42+
sh 'git clone [email protected]:elastic/docs.git'
43+
sh 'git clone [email protected]:elastic/cloud-on-k8s.git'
44+
sh """
45+
$WORKSPACE/docs/build_docs \
46+
--doc $WORKSPACE/cloud-on-k8s/docs/index.asciidoc \
47+
--out $WORKSPACE/cloud-on-k8s/docs/html \
48+
--chunk 1
49+
"""
50+
sh 'test -e $WORKSPACE/cloud-on-k8s/docs/html/index.html'
4351
}
4452
}
4553
stage("Run smoke E2E tests") {

0 commit comments

Comments
 (0)