summaryrefslogtreecommitdiffstats
path: root/jjb/cicn
diff options
context:
space:
mode:
authorLuca Muscariello <lumuscar+fdio@cisco.com>2018-02-23 16:29:57 +0100
committerLuca Muscariello <lumuscar+fdio@cisco.com>2018-02-23 20:58:36 +0000
commitf4ea587cbeb79f8cfd8a04685f0a7f0e1cdd6298 (patch)
treeb271aed045289db1119dafb2a9094639e4eafc6a /jjb/cicn
parent4e33c66bc42c8be83c5e2425da74947b9f53f32a (diff)
fixes for cicn documentations:
- LongBow: removing JJB dependency tree for docs which is useless as it triggers the whole job dependency graph - Libparc: added documentation to be availeble at docs.fd.io Change-Id: I052ae76cdf6507e0dbeb8811c00ce6501708380e Signed-off-by: Luca Muscariello <lumuscar+fdio@cisco.com>
Diffstat (limited to 'jjb/cicn')
-rw-r--r--jjb/cicn/cicn.yaml145
-rw-r--r--jjb/cicn/include-raw-cicn-libparc-docs.sh74
2 files changed, 217 insertions, 2 deletions
diff --git a/jjb/cicn/cicn.yaml b/jjb/cicn/cicn.yaml
index c7252a864..a5e0243fb 100644
--- a/jjb/cicn/cicn.yaml
+++ b/jjb/cicn/cicn.yaml
@@ -24,8 +24,8 @@
jobs:
- 'cicn-libparc-verify-{stream}-{os}'
- 'cicn-libparc-merge-{stream}-{os}'
- # - 'cicn-libparc-docs-verify-{stream}'
- # - 'cicn-libparc-docs-merge-{stream}'
+ - 'cicn-libparc-docs-verify-{stream}'
+ - 'cicn-libparc-docs-merge-{stream}'
project: 'cicn'
os:
- ubuntu1604:
@@ -561,6 +561,9 @@
build-timeout: '{build-timeout}'
triggers:
+ - reverse:
+ jobs: 'cicn-longbow-merge-{stream}-ubuntu1604'
+ result: 'success'
- gerrit-trigger-patch-merged:
name: '{project}'
branch: '{branch}'
@@ -648,6 +651,144 @@
maven-version: 'mvn33-new'
- job-template:
+ name: 'cicn-libparc-docs-merge-{stream}'
+
+ project-type: freestyle
+ node: ubuntu1604-basebuild-8c-32g
+ concurrent: true
+
+ logrotate:
+ daysToKeep: '{build-days-to-keep}'
+ numToKeep: '{build-num-to-keep}'
+ artifactDaysToKeep: '{build-artifact-days-to-keep}'
+ artifactNumToKeep: '{build-artifact-num-to-keep}'
+
+ parameters:
+ - project-parameter:
+ project: '{project}'
+ - gerrit-parameter:
+ branch: '{branch}'
+ - os-parameter:
+ os: 'ubuntu1604'
+ - maven-exec:
+ maven-version: 'mvn33-new'
+
+ scm:
+ - gerrit-trigger-scm:
+ credentials-id: 'jenkins-gerrit-credentials'
+ refspec: ''
+ choosing-strategy: 'default'
+
+ wrappers:
+ - fdio-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ - gerrit:
+ server-name: 'Primary'
+ trigger-on:
+ - comment-added-contains-event:
+ comment-contains-value: 'run-docs'
+ projects:
+ - project-compare-type: 'ANT'
+ project-pattern: '{project}'
+ branches:
+ - branch-compare-type: 'ANT'
+ branch-pattern: '**/{branch}'
+ skip-vote:
+ successful: true
+ failed: true
+ unstable: true
+ notbuilt: true
+
+ builders:
+ - maven-target:
+ maven-version: 'mvn33-new'
+ goals: '--version'
+ settings: 'vpp-settings'
+ settings-type: cfp
+ global-settings: 'global-settings'
+ global-settings-type: cfp
+ - provide-maven-settings:
+ settings-file: 'cicn-settings'
+ global-settings-file: 'global-settings'
+ - shell:
+ !include-raw-escape:
+ - include-raw-cicn-libparc-docs.sh
+ publishers:
+ - archive:
+ artifacts: 'libparc/build/documentation/*.tar'
+ allow-empty: 'true'
+ fingerprint: false
+ only-if-success: true
+ default-excludes: false
+ - fdio-infra-shiplogs:
+ maven-version: 'mvn33-new'
+
+- job-template:
+ name: 'cicn-libparc-docs-verify-{stream}'
+
+ project-type: freestyle
+ node: ubuntu1604-basebuild-8c-32g
+ concurrent: true
+
+ logrotate:
+ daysToKeep: '{build-days-to-keep}'
+ numToKeep: '{build-num-to-keep}'
+ artifactDaysToKeep: '{build-artifact-days-to-keep}'
+ artifactNumToKeep: '{build-artifact-num-to-keep}'
+
+ parameters:
+ - project-parameter:
+ project: '{project}'
+ - gerrit-parameter:
+ branch: '{branch}'
+ - os-parameter:
+ os: 'ubuntu1604'
+ - maven-exec:
+ maven-version: 'mvn33-new'
+
+ scm:
+ - gerrit-trigger-scm:
+ credentials-id: 'jenkins-gerrit-credentials'
+ refspec: ''
+ choosing-strategy: 'default'
+
+ wrappers:
+ - fdio-infra-wrappers:
+ build-timeout: '{build-timeout}'
+
+ triggers:
+ - gerrit-trigger-patch-submitted:
+ name: '{project}'
+ branch: '{branch}'
+
+ builders:
+ - maven-target:
+ maven-version: 'mvn33-new'
+ goals: '--version'
+ settings: 'vpp-settings'
+ settings-type: cfp
+ global-settings: 'global-settings'
+ global-settings-type: cfp
+ - provide-maven-settings:
+ settings-file: 'cicn-settings'
+ global-settings-file: 'global-settings'
+ - shell:
+ !include-raw-escape:
+ - include-raw-cicn-libparc-docs.sh
+ publishers:
+ - archive:
+ artifacts: 'libparc/build/documentation/*.tar'
+ allow-empty: 'true'
+ fingerprint: false
+ only-if-success: true
+ default-excludes: false
+ - fdio-infra-shiplogs:
+ maven-version: 'mvn33-new'
+
+
+- job-template:
name: 'cicn-libccnx-common-merge-{stream}-{os}'
project-type: freestyle
diff --git a/jjb/cicn/include-raw-cicn-libparc-docs.sh b/jjb/cicn/include-raw-cicn-libparc-docs.sh
new file mode 100644
index 000000000..50f0ee530
--- /dev/null
+++ b/jjb/cicn/include-raw-cicn-libparc-docs.sh
@@ -0,0 +1,74 @@
+#!/bin/bash
+set -xe -o pipefail
+
+update_cmake_repo() {
+ cat /etc/resolv.conf
+ echo "nameserver 8.8.8.8" | sudo tee -a /etc/resolv.conf
+ cat /etc/resolv.conf
+
+ CMAKE_INSTALL_SCRIPT_URL="https://cmake.org/files/v3.8/cmake-3.8.0-Linux-x86_64.sh"
+ CMAKE_INSTALL_SCRIPT="/tmp/install_cmake.sh"
+ curl ${CMAKE_INSTALL_SCRIPT_URL} > ${CMAKE_INSTALL_SCRIPT}
+
+ sudo mkdir -p /opt/cmake
+ sudo bash ${CMAKE_INSTALL_SCRIPT} --skip-license --prefix=/opt/cmake
+ export PATH=/opt/cmake/bin:$PATH
+}
+
+cd libparc
+
+[ "$DOCS_REPO_URL" ] || DOCS_REPO_URL="https://nexus.fd.io/content/sites/site"
+[ "$PROJECT_PATH" ] || PROJECT_PATH="io/fd/cicn/libparc"
+[ "$DOC_FILE" ] || DOC_FILE="cicn.libparc.docs.zip"
+[ "$DOC_DIR" ] || DOC_DIR="build/documentation/generated-documentation/html"
+[ "$SITE_DIR" ] || SITE_DIR="build/documentation/deploy-site/"
+[ "$RESOURCES_DIR" ] || RESOURCES_DIR=${SITE_DIR}/src/site/resources
+[ "$MVN" ] || MVN="/opt/apache/maven/bin/mvn"
+[ "$VERSION" ] || VERSION=$(bash scripts/version rpm-version)
+
+echo "Current directory: $(pwd)"
+
+update_cmake_repo
+mkdir -p build
+pushd build
+cmake ..
+make documentation
+popd
+
+if [[ ${JOB_NAME} == *merge* ]]; then
+ mkdir -p $(dirname ${RESOURCES_DIR})
+ mv -f ${DOC_DIR} ${RESOURCES_DIR}
+ cd ${SITE_DIR}
+ find . -type f '(' -name '*.md5' -o -name '*.dot' -o -name '*.map' ')' -delete
+ cat > pom.xml << EOF
+ <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>io.fd.vpp</groupId>
+ <artifactId>docs</artifactId>
+ <version>1.0.0</version>
+ <packaging>pom</packaging>
+
+ <properties>
+ <generateReports>false</generateReports>
+ </properties>
+
+ <build>
+ <extensions>
+ <extension>
+ <groupId>org.apache.maven.wagon</groupId>
+ <artifactId>wagon-webdav-jackrabbit</artifactId>
+ <version>2.9</version>
+ </extension>
+ </extensions>
+ </build>
+ <distributionManagement>
+ <site>
+ <id>fdio-site</id>
+ <url>dav:${DOCS_REPO_URL}/${PROJECT_PATH}/${VERSION}</url>
+ </site>
+ </distributionManagement>
+ </project>
+EOF
+ ${MVN} site:site site:deploy -gs "${GLOBAL_SETTINGS_FILE}" -s "${SETTINGS_FILE}" -T 4C
+ cd -
+fi