refctor: rework ci to ue ansible-lint and fix molecule
This commit is contained in:
parent
3503b1b70b
commit
d834a55b2b
15
.later.yml
15
.later.yml
@ -1,15 +0,0 @@
|
|||||||
---
|
|
||||||
ansible:
|
|
||||||
custom_modules:
|
|
||||||
- iptables_raw
|
|
||||||
- openssl_pkcs12
|
|
||||||
- proxmox_kvm
|
|
||||||
- ucr
|
|
||||||
- corenetworks_dns
|
|
||||||
- corenetworks_token
|
|
||||||
|
|
||||||
rules:
|
|
||||||
exclude_files:
|
|
||||||
- "LICENSE*"
|
|
||||||
- "**/*.md"
|
|
||||||
- "**/*.ini"
|
|
@ -9,11 +9,11 @@ steps:
|
|||||||
- name: generate
|
- name: generate
|
||||||
image: quay.io/thegeeklab/ansible-doctor
|
image: quay.io/thegeeklab/ansible-doctor
|
||||||
environment:
|
environment:
|
||||||
ANSIBLE_DOCTOR_EXCLUDE_FILES: molecule/
|
ANSIBLE_DOCTOR_EXCLUDE_FILES: "['molecule/']"
|
||||||
ANSIBLE_DOCTOR_FORCE_OVERWRITE: "true"
|
ANSIBLE_DOCTOR_RENDERER__FORCE_OVERWRITE: "true"
|
||||||
ANSIBLE_DOCTOR_LOG_LEVEL: INFO
|
ANSIBLE_DOCTOR_LOGGING__LEVEL: info
|
||||||
ANSIBLE_DOCTOR_ROLE_NAME: ${CI_REPO_NAME}
|
ANSIBLE_DOCTOR_ROLE__NAME: ${CI_REPO_NAME}
|
||||||
ANSIBLE_DOCTOR_TEMPLATE: readme
|
ANSIBLE_DOCTOR_TEMPLATE__NAME: readme
|
||||||
|
|
||||||
- name: format
|
- name: format
|
||||||
image: quay.io/thegeeklab/alpine-tools
|
image: quay.io/thegeeklab/alpine-tools
|
||||||
|
@ -6,10 +6,10 @@ when:
|
|||||||
- ${CI_REPO_DEFAULT_BRANCH}
|
- ${CI_REPO_DEFAULT_BRANCH}
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: ansible-later
|
- name: ansible-lint
|
||||||
image: quay.io/thegeeklab/ansible-later:4
|
image: quay.io/thegeeklab/ansible-dev-tools:1
|
||||||
commands:
|
commands:
|
||||||
- ansible-later
|
- ansible-lint
|
||||||
environment:
|
environment:
|
||||||
FORCE_COLOR: "1"
|
FORCE_COLOR: "1"
|
||||||
|
|
||||||
|
20
.yamllint
Normal file
20
.yamllint
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
extends: default
|
||||||
|
|
||||||
|
rules:
|
||||||
|
truthy:
|
||||||
|
allowed-values: ["True", "False"]
|
||||||
|
comments:
|
||||||
|
min-spaces-from-content: 1
|
||||||
|
comments-indentation: False
|
||||||
|
line-length: disable
|
||||||
|
braces:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 1
|
||||||
|
brackets:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 0
|
||||||
|
indentation: enable
|
||||||
|
octal-values:
|
||||||
|
forbid-implicit-octal: True
|
||||||
|
forbid-explicit-octal: True
|
@ -21,5 +21,3 @@ galaxy_info:
|
|||||||
- system
|
- system
|
||||||
- upgrade
|
- upgrade
|
||||||
dependencies: []
|
dependencies: []
|
||||||
collections:
|
|
||||||
- community.general
|
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
- name: Upgrade packages
|
- name: Upgrade packages
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
update_cache: yes
|
update_cache: True
|
||||||
upgrade: dist
|
upgrade: dist
|
||||||
|
|
||||||
- name: Remove package lock
|
- name: Remove package lock
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
---
|
---
|
||||||
- ansible.builtin.include_tasks: "{{ lookup('first_found', params) }}"
|
- name: Manage packages
|
||||||
|
ansible.builtin.include_tasks: "{{ lookup('first_found', params) }}"
|
||||||
vars:
|
vars:
|
||||||
params:
|
params:
|
||||||
files:
|
files:
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
- name: Upgrade packages
|
- name: Upgrade packages
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name: "*"
|
name: "*"
|
||||||
state: latest
|
state: latest # noqa package-latest
|
||||||
exclude: "{{ update_packages_exclude }}"
|
exclude: "{{ update_packages_exclude }}"
|
||||||
tags:
|
tags:
|
||||||
- skip_ansible_later
|
- skip_ansible_later
|
||||||
|
Loading…
Reference in New Issue
Block a user