New doc jobs on lf-build1
[releng.git] / jjb / opnfvdocs / docs-rtd.yaml
1 - project:
2     name: docs-rtd
3     jobs:
4         - 'docs-merge-rtd-{stream}'
5         - 'docs-verify-rtd-{stream}'
6
7     stream:
8         - danube:
9             branch: 'master'
10         - colorado:
11             branch: 'stable/colorado'
12
13     project: 'opnfvdocs'
14     rtdproject: 'opnfv'
15     # TODO: Archive Artifacts
16
17 - job-template:
18     name: 'docs-merge-rtd-{stream}'
19
20     project-type: freestyle
21
22     parameters:
23         - label:
24             name: SLAVE_LABEL
25             default: 'lf-build1'
26             description: 'Slave label on Jenkins'
27         - project-parameter:
28             project: '{project}'
29             branch: '{branch}'
30         - string:
31             name: GIT_BASE
32             default: https://gerrit.opnfv.org/gerrit/releng
33             description: 'Git URL to use on this Jenkins Slave'
34     scm:
35         - git-scm
36
37     triggers:
38         - gerrit-trigger-change-merged
39
40     builders:
41         - shell: !include-raw: docs-post-rtd.sh
42
43 - job-template:
44     name: 'docs-verify-rtd-{stream}'
45
46     project-type: freestyle
47
48     parameters:
49         - label:
50             name: SLAVE_LABEL
51             default: 'lf-build1'
52             description: 'Slave label on Jenkins'
53         - project-parameter:
54             project: '{project}'
55             branch: '{branch}'
56         - string:
57             name: GIT_BASE
58             default: https://gerrit.opnfv.org/gerrit/releng
59             description: 'Git URL to use on this Jenkins Slave'
60     scm:
61         - git-scm-gerrit
62
63     triggers:
64         - gerrit-trigger-patchset-created:
65             server: 'gerrit.opnfv.org'
66             project: '**'
67             branch: '{branch}'
68             files: 'docs/**/*.rst'
69             skip-vote:
70                 successful: true
71                 failed: true
72                 unstable: true
73                 notbuilt: true
74         - timed: 'H H * * *'
75
76     builders:
77         - shell: |
78             if [ "$GERRIT_PROJECT" != "opnfvdocs" ]; then
79                 cd opnfvdocs/submodules/$GERRIT_PROJECT
80                 git fetch origin $GERRIT_REFSPEC && git checkout FETCH_HEAD
81             else
82                 git fetch origin $GERRIT_REFSPEC && git checkout FETCH_HEAD
83             fi
84         - shell: |
85             virtualenv $WORKSPACE/venv
86             source $WORKSPACE/venv/bin/activate
87             pip install --upgrade pip
88             pip freeze
89             pip install tox
90             tox -edocs