Questions tagged [ansible-lint]

[ansible-lint](https://ansible-lint.readthedocs.io/) is the official linter for Ansible content such playbooks, collections, roles.

23 questions
0
votes
1 answer

How to fix Ansible Lint warning: no-jinja-when

I just got warning raised by Ansible Lint. This is the issue: [no-jinja-when] [HIGH] No Jinja2 in when You can skip specific rules or tags by adding them to your configuration file: # .ansible-lint warn_list: # or 'skip_list' to silence them…
Adnan.
  • 33
  • 5
0
votes
0 answers

Why are warnings considered as fatal

When I run ansible-lint on my ansible content, I get the following result WARNING Listing 11 violation(s) that are fatal download-monitoring-artifacts.yml:48: yaml: line too long (161 > 160 characters)…
grafra
  • 411
  • 6
  • 16
0
votes
1 answer

What is the recommended action for molecule lint

The internet normally recommends the following snippet to configure molecule lint: lint: | set -e yamllint . ansible-lint . Sometimes there is also an additional flake8. But Lets ignorethis for a while. I have two issues with that: First, the…
grafra
  • 411
  • 6
  • 16
0
votes
2 answers

Why does molecule lint use different rules than ansible-lint?

I am new to using molecule and want to enable molecule for my ansible content. This content is a folder containing three playbooks and a folder roles with 8 roles which are used in the playbooks. The playbooks run without problems. Now I wanted to…
grafra
  • 411
  • 6
  • 16
0
votes
1 answer

Gitlab CI not displaying complete output in terminal

I have created a pipeline which performs ansible-lint on $CI_PROJECT_DIR. The problem is the complete output is not shown in UI as compared to running on my local machine. You can notice the difference in output for both. Below is the output from my…
0
votes
2 answers

Run ansible-lint through subdirectories within a gitlab role

I am trying to add a validation step to a gitlab repo holding a single ansible role (with no playbook). The structure of the role looks like : .gitlab-ci.yml tasks/ templates/ files/ vars/ handlers/ With the gitlab-ci looking like : stages: -…
Marvin
  • 1,650
  • 4
  • 19
  • 41
0
votes
1 answer

Exit code status in AIX with pipe for ansible

[306] Shells that use pipes should set the pipefail option roles/Auto_Config_Agent/tasks/AUTO_configure_AIX.yml:10 Task/Handler: Define customer name Does anyone know how to do this on AIX? For linux just use /bin/bash set -o…
Luis Henrique
  • 701
  • 15
  • 36
0
votes
1 answer

How can I know which version of pip package to install?

I'm using Ubuntu 14.04, with Python 3.4.3. I want to install the latest version of ansible-lint that is supported on that Ubuntu version and with this Python version. One of the dependencies of the ansible-lint package is ansible. When I simply use…
ChikChak
  • 936
  • 19
  • 44
1
2