Report Kubernetes cluster and pod resource requests vs usage and generate static HTML
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

127 lines
2.9 KiB

  1. minimum_pre_commit_version: 1.21.0
  2. repos:
  3. # meta
  4. - repo: meta
  5. hooks:
  6. - id: check-hooks-apply
  7. - id: check-useless-excludes
  8. - repo: https://codeberg.org/hjacobs/kube-manifest-lint
  9. rev: 0.2.0
  10. hooks:
  11. - id: kube-manifest-lint
  12. exclude: ^unsupported/chart/kube-resource-report/templates/.*$|kustomization.yaml
  13. # formatters
  14. - repo: https://github.com/asottile/reorder_python_imports
  15. rev: v2.3.0
  16. hooks:
  17. - id: reorder-python-imports
  18. - repo: https://github.com/ambv/black
  19. rev: 19.10b0
  20. hooks:
  21. - id: black
  22. - repo: https://github.com/asottile/pyupgrade
  23. rev: v2.6.2
  24. hooks:
  25. - id: pyupgrade
  26. stages: [push]
  27. # linters
  28. - repo: https://github.com/PyCQA/bandit
  29. rev: 1.6.2
  30. hooks:
  31. - id: bandit
  32. args: ["-x", "tests"]
  33. stages: [push]
  34. - repo: https://github.com/PyCQA/pydocstyle
  35. rev: 5.0.2
  36. hooks:
  37. - id: pydocstyle
  38. args: ["--ignore=D10,D21,D202"]
  39. - repo: local
  40. hooks:
  41. - id: safety
  42. name: safety
  43. entry: safety
  44. language: system
  45. pass_filenames: false
  46. args: ["check", "--bare"]
  47. stages: [push]
  48. - id: poetry
  49. name: poetry
  50. description: Validates the structure of the pyproject.toml file
  51. entry: poetry check
  52. language: system
  53. pass_filenames: false
  54. files: ^pyproject.toml$
  55. stages: [push]
  56. - repo: https://github.com/adrienverge/yamllint
  57. rev: v1.23.0
  58. hooks:
  59. - id: yamllint
  60. args: ["--strict", "-d", "{rules: {line-length: {max: 180}}}"]
  61. #
  62. exclude: >
  63. (?x)^(
  64. ^unsupported/chart/kube-resource-report/templates/.*$
  65. )
  66. #
  67. - repo: https://github.com/pre-commit/mirrors-mypy
  68. rev: v0.782
  69. hooks:
  70. - id: mypy
  71. - repo: https://github.com/pryorda/dockerfilelint-precommit-hooks
  72. rev: v0.1.0
  73. hooks:
  74. - id: dockerfilelint
  75. stages: [commit] # required
  76. - repo: https://gitlab.com/pycqa/flake8
  77. rev: 3.8.3
  78. hooks:
  79. - id: flake8
  80. - repo: https://github.com/pre-commit/pre-commit-hooks
  81. rev: v3.1.0
  82. hooks:
  83. - id: check-added-large-files
  84. - id: check-docstring-first
  85. - id: debug-statements
  86. - id: end-of-file-fixer
  87. - id: trailing-whitespace
  88. - id: check-ast
  89. - id: check-builtin-literals
  90. - id: detect-private-key
  91. - id: mixed-line-ending
  92. - id: name-tests-test
  93. args: ["--django"]
  94. - repo: https://github.com/pre-commit/pygrep-hooks
  95. rev: v1.5.1
  96. hooks:
  97. # - id: rst-backticks
  98. - id: python-use-type-annotations
  99. - id: python-no-log-warn
  100. - id: python-no-eval
  101. - id: python-check-mock-methods
  102. - id: python-check-blanket-noqa
  103. # commit-msg
  104. # http://jorisroovers.com/gitlint/#using-gitlint-through-pre-commit
  105. - repo: https://github.com/jorisroovers/gitlint
  106. rev: v0.13.1
  107. hooks:
  108. - id: gitlint