Skip to content
Snippets Groups Projects
Commit 5f34058d authored by James Ward's avatar James Ward Committed by Liz Rice
Browse files

Support Linting YAML as part of Travis CI build (#554)

* add yamllint command to travis CI

installs and runs a linter across the YAML in the
project to ensure consistency in the written YAML.

this uses yamllint and the default yamllint config with
"truthy" and "line-length" disabled.

* run dos2unix on CRLF files

* YAMLLINT: remove trailing spaces

* YAMLLint: add YAML document start

* YAMLLint: too many spaces around bracket

* YAMLLint: fix indentation

* YAMLLint: remove duplicate key

* YAMLLint: newline at end of file

* YAMLLint: Too few spaces after comma

* YAMLLint: too many spaces after colon
parent dc14cb14
No related branches found
No related tags found
No related merge requests found
Showing
with 7877 additions and 7869 deletions
---
env:
- GO111MODULE=on
- KUBEBENCH_CFG=/etc/kube-bench/cfg
......
......@@ -10,10 +10,12 @@ notifications:
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y rpm
- pip install --user yamllint==1.18.0
- gem install --no-ri --no-rdoc fpm
- go get -t -v ./...
script:
- yamllint -c ./.yamllint.yaml .
- GO111MODULE=on go test ./...
- IMAGE_NAME=kube-bench make build-docker
- docker run -v `pwd`:/host kube-bench install
......
---
extends: default
rules:
line-length: disable
truthy: disable
......@@ -774,7 +774,6 @@ groups:
op: has
value: "/etc/origin/master/ca-bundle.crt"
set: true
test_items:
- flag: "masterCA"
compare:
op: has
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment