Merged in ITPLT-3977-add-direnv-pre-commit-to-dc-deployments-automation (pull request #215)

ITPLT-3977 add direnv pre commit to dc deployments automation

Approved-by: Lee Goolsbee
This commit is contained in:
Geoff Jacobs
2024-08-19 22:50:49 +00:00
15 changed files with 546 additions and 428 deletions

View File

@@ -8,4 +8,5 @@ skip_list:
- name[casing] # so many of our task names aren't capitalized
- name[missing] # some tasks have no name
- risky-file-permissions
- var-naming[no-role-prefix] # many, many warnings
- yaml # many, many warnings

3
.envrc Normal file
View File

@@ -0,0 +1,3 @@
layout pipenv
pre-commit install
ansible-galaxy install -r requirements.yml

3
.gitignore vendored
View File

@@ -5,7 +5,8 @@ __pycache__
*.pyc
/.venv
\#*\#
.envrc
.direnv
.idea
.vscode
ansible_collections
.DS_Store

View File

@@ -19,9 +19,10 @@ repos:
- --template={}
- --pattern=[a-zA-Z0-9]{1,10}-[0-9]{1,6}
- repo: https://github.com/ansible/ansible-lint.git
rev: v24.2.2
rev: v24.7.0
hooks:
- id: ansible-lint
stages: [manual]
additional_dependencies:
- .
- ansible-core==2.16.6

View File

@@ -19,6 +19,7 @@ ansible-compat = "==4.1.11"
docker = "==7.0.0"
pytest = "*"
pytest-testinfra = "*"
pre-commit = "*"
[requires]
python_version = "3"

849
Pipfile.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -11,12 +11,22 @@ options:
definitions:
caches:
ansible-collections: ansible_collections
pre-commit: ~/.cache/pre-commit
services:
docker:
memory: 4096
pipelines:
default:
- step:
name: Pre-commit
image: python:3.9
caches:
- pre-commit
script:
- apt update && apt install -y pipenv
- pipenv sync --dev
- pipenv run pre-commit run --all-files
- step:
name: Pre Parallelization stage
script: