Merge "zuul: Add site linting gates"
This commit is contained in:
commit
94ec5eac0d
42
.zuul.yaml
42
.zuul.yaml
@ -15,3 +15,45 @@
|
|||||||
- docs-on-readthedocs
|
- docs-on-readthedocs
|
||||||
vars:
|
vars:
|
||||||
rtd_webhook_id: '47687'
|
rtd_webhook_id: '47687'
|
||||||
|
check:
|
||||||
|
jobs:
|
||||||
|
- airship-seaworthy-site-lint-gate
|
||||||
|
- airskiff-site-lint-gate
|
||||||
|
gate:
|
||||||
|
jobs:
|
||||||
|
- airship-seaworthy-site-lint-gate
|
||||||
|
- airskiff-site-lint-gate
|
||||||
|
|
||||||
|
- nodeset:
|
||||||
|
name: airship-treasuremap-single-node
|
||||||
|
nodes:
|
||||||
|
- name: primary
|
||||||
|
label: ubuntu-xenial
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: airship-seaworthy-site-lint-gate
|
||||||
|
nodeset: airship-treasuremap-single-node
|
||||||
|
timeout: 900
|
||||||
|
pre-run:
|
||||||
|
- tools/gate/playbooks/install-docker.yaml
|
||||||
|
- tools/gate/playbooks/git-config.yaml
|
||||||
|
run: tools/gate/playbooks/airship-seaworthy-site-lint.yaml
|
||||||
|
required-projects:
|
||||||
|
- openstack/airship-pegleg
|
||||||
|
irrelevant-files:
|
||||||
|
- ^.*\.rst$
|
||||||
|
- ^doc/.*$
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: airskiff-site-lint-gate
|
||||||
|
nodeset: airship-treasuremap-single-node
|
||||||
|
timeout: 900
|
||||||
|
pre-run:
|
||||||
|
- tools/gate/playbooks/install-docker.yaml
|
||||||
|
- tools/gate/playbooks/git-config.yaml
|
||||||
|
run: tools/gate/playbooks/airskiff-site-lint.yaml
|
||||||
|
required-projects:
|
||||||
|
- openstack/airship-pegleg
|
||||||
|
irrelevant-files:
|
||||||
|
- ^.*\.rst$
|
||||||
|
- ^doc/.*$
|
||||||
|
26
tools/gate/lint-site.sh
Executable file
26
tools/gate/lint-site.sh
Executable file
@ -0,0 +1,26 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
set -xe
|
||||||
|
|
||||||
|
: "${PEGLEG_PATH:=../airship-pegleg}"
|
||||||
|
: "${PEGLEG_IMG:=quay.io/airshipit/pegleg:b7556bd89e99f2a6539e97d5a4ac6738751b9c55}"
|
||||||
|
|
||||||
|
: "${PEGLEG:=${PEGLEG_PATH}/tools/pegleg.sh}"
|
||||||
|
|
||||||
|
# TODO(drewwalters96): make Treasuremap sites P001 and P009 compliant.
|
||||||
|
IMAGE=${PEGLEG_IMG} TERM_OPTS=" " \
|
||||||
|
${PEGLEG} site -r . lint "$1" -x P001 -x P009
|
23
tools/gate/playbooks/airship-seaworthy-site-lint.yaml
Normal file
23
tools/gate/playbooks/airship-seaworthy-site-lint.yaml
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
- hosts: primary
|
||||||
|
tasks:
|
||||||
|
- name: Lint airship-seaworthy site
|
||||||
|
shell: |
|
||||||
|
set -xe;
|
||||||
|
./tools/gate/lint-site.sh airship-seaworthy
|
||||||
|
args:
|
||||||
|
chdir: "{{ zuul.project.src_dir }}"
|
||||||
|
become: yes
|
23
tools/gate/playbooks/airskiff-site-lint.yaml
Normal file
23
tools/gate/playbooks/airskiff-site-lint.yaml
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
- hosts: primary
|
||||||
|
tasks:
|
||||||
|
- name: Lint airskiff site
|
||||||
|
shell: |
|
||||||
|
set -xe;
|
||||||
|
./tools/gate/lint-site.sh airskiff
|
||||||
|
args:
|
||||||
|
chdir: "{{ zuul.project.src_dir }}"
|
||||||
|
become: yes
|
26
tools/gate/playbooks/git-config.yaml
Normal file
26
tools/gate/playbooks/git-config.yaml
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
- hosts: primary
|
||||||
|
tasks:
|
||||||
|
- name: Git config
|
||||||
|
shell: |
|
||||||
|
set -xe;
|
||||||
|
|
||||||
|
tee .git/config << EOF
|
||||||
|
[remote "origin"]
|
||||||
|
url = https://git.openstack.org/openstack/airship-treasuremap.git
|
||||||
|
EOF
|
||||||
|
args:
|
||||||
|
chdir: "{{ zuul.project.src_dir }}"
|
30
tools/gate/playbooks/install-docker.yaml
Normal file
30
tools/gate/playbooks/install-docker.yaml
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
|
||||||
|
- hosts: primary
|
||||||
|
tasks:
|
||||||
|
- name: Install Docker CE
|
||||||
|
shell: |
|
||||||
|
set -xe;
|
||||||
|
|
||||||
|
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
|
||||||
|
sudo apt-add-repository \
|
||||||
|
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
|
||||||
|
$(lsb_release -cs) \
|
||||||
|
stable"
|
||||||
|
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install --no-install-recommends -y docker-ce
|
||||||
|
args:
|
||||||
|
chdir: "{{ zuul.project.src_dir }}"
|
Loading…
Reference in New Issue
Block a user