Skip to content

Bump ansible-lint from 6.5.2 to 6.7.0 in /.github/workflows/requirements #550

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .ansible-lint
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
skip_list:
- name[template]
- yaml[line-length]
2 changes: 1 addition & 1 deletion .github/workflows/requirements/requirements_molecule.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ansible-core==2.13.4
jinja2==3.1.2
ansible-lint==6.5.2
ansible-lint==6.7.0
yamllint==1.28.0
molecule[docker]==4.0.1
docker==6.0.0
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -29,7 +29,7 @@ TESTS:
* Add SLES 15 to all Molecule tests.
* Create downgrade and upgrade tests for NGINX Plus.
* Remove Yamllint (Ansible Lint now incorporates Yamllint).
* Skip Ansible Lint line length rule.
* Skip Ansible Lint line length and no templates in name rules. Slightly refactor code to incorporate changes added to Ansible Lint 6.7.0.

## 0.23.1 (April 6, 2022)

4 changes: 2 additions & 2 deletions molecule/downgrade_plus/prepare.yml
Original file line number Diff line number Diff line change
@@ -3,14 +3,14 @@
hosts: localhost
gather_facts: false
tasks:
- name: Create ephemeral license certificate file from b64 decoded env var
- name: Create ephemeral license certificate file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_CRT') | b64decode }}"
dest: ../../files/license/nginx-repo.crt
force: false
mode: 0444

- name: Create ephemeral license key file from b64 decoded env var
- name: Create ephemeral license key file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_KEY') | b64decode }}"
dest: ../../files/license/nginx-repo.key
4 changes: 2 additions & 2 deletions molecule/plus/prepare.yml
Original file line number Diff line number Diff line change
@@ -3,14 +3,14 @@
hosts: localhost
gather_facts: false
tasks:
- name: Create ephemeral license certificate file from b64 decoded env var
- name: Create ephemeral license certificate file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_CRT') | b64decode }}"
dest: ../../files/license/nginx-repo.crt
force: false
mode: 0444

- name: Create ephemeral license key file from b64 decoded env var
- name: Create ephemeral license key file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_KEY') | b64decode }}"
dest: ../../files/license/nginx-repo.key
4 changes: 2 additions & 2 deletions molecule/uninstall_plus/prepare.yml
Original file line number Diff line number Diff line change
@@ -3,14 +3,14 @@
hosts: localhost
gather_facts: false
tasks:
- name: Create ephemeral license certificate file from b64 decoded env var
- name: Create ephemeral license certificate file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_CRT') | b64decode }}"
dest: ../../files/license/nginx-repo.crt
force: false
mode: 0444

- name: Create ephemeral license key file from b64 decoded env var
- name: Create ephemeral license key file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_KEY') | b64decode }}"
dest: ../../files/license/nginx-repo.key
4 changes: 2 additions & 2 deletions molecule/upgrade_plus/prepare.yml
Original file line number Diff line number Diff line change
@@ -3,14 +3,14 @@
hosts: localhost
gather_facts: false
tasks:
- name: Create ephemeral license certificate file from b64 decoded env var
- name: Create ephemeral license certificate file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_CRT') | b64decode }}"
dest: ../../files/license/nginx-repo.crt
force: false
mode: 0444

- name: Create ephemeral license key file from b64 decoded env var
- name: Create ephemeral license key file from b64 decoded env var # noqa template-instead-of-copy
ansible.builtin.copy:
content: "{{ lookup('env', 'NGINX_KEY') | b64decode }}"
dest: ../../files/license/nginx-repo.key
2 changes: 1 addition & 1 deletion tasks/keys/setup-keys.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
- name: (Alpine Linux) Set up signing key
when: ansible_facts['os_family'] == "Alpine"
block:
- name: (Alpine Linux) Set up NGINX signing key URL
ansible.builtin.set_fact:
@@ -10,7 +11,6 @@
url: "{{ keysite }}"
dest: /etc/apk/keys/nginx_signing.rsa.pub
mode: 0400
when: ansible_facts['os_family'] == "Alpine"

- name: (Debian/Red Hat/SLES OSs) Set up NGINX signing key URL
ansible.builtin.set_fact:
4 changes: 2 additions & 2 deletions tasks/main.yml
Original file line number Diff line number Diff line change
@@ -31,6 +31,8 @@
tags: nginx_key

- name: "{{ nginx_setup | capitalize }} NGINX"
when: nginx_enable | bool
tags: nginx_enable
block:
- name: "{{ nginx_setup | capitalize }} NGINX Open Source"
ansible.builtin.include_tasks: "{{ role_path }}/tasks/opensource/install-oss.yml"
@@ -69,8 +71,6 @@
- ansible_facts['service_mgr'] == "systemd"
- nginx_service_modify | bool
tags: nginx_modify_systemd
when: nginx_enable | bool
tags: nginx_enable

- name: Trigger handlers if necessary
ansible.builtin.meta: flush_handlers
10 changes: 5 additions & 5 deletions tasks/modules/install-modules.yml
Original file line number Diff line number Diff line change
@@ -8,6 +8,11 @@
- nginx_install_epel_release | bool

- name: (RHEL) Install GeoIP2 and/or OpenTracing EPEL dependencies
when:
- ansible_facts['distribution'] == "RedHat"
- (ansible_facts['distribution_major_version'] == 7 and '"geoip2" in nginx_modules')
or '"opentracing" in nginx_modules'
- nginx_install_epel_release | bool
block:
- name: (RHEL) Import EPEL GPG key
ansible.builtin.rpm_key:
@@ -17,11 +22,6 @@
- name: (RHEL) Install package dependencies
ansible.builtin.yum:
name: https://dl.fedoraproject.org/pub/epel/epel-release-latest-{{ ansible_facts['distribution_major_version'] }}.noarch.rpm
when:
- ansible_facts['distribution'] == "RedHat"
- (ansible_facts['distribution_major_version'] == 7 and '"geoip2" in nginx_modules')
or '"opentracing" in nginx_modules'
- nginx_install_epel_release | bool

- name: Setup NGINX modules
ansible.builtin.package:
6 changes: 3 additions & 3 deletions tasks/opensource/install-alpine.yml
Original file line number Diff line number Diff line change
@@ -17,6 +17,9 @@
notify: (Handler) Run NGINX

- name: (Alpine Linux) Upgrade NGINX workaround ('nginx_setup' is set to 'upgrade' and 'nginx_version' is not defined)
when:
- nginx_setup == 'upgrade'
- nginx_version is not defined
block:
- name: (Alpine Linux) Check if there are NGINX upgrades available
ansible.builtin.command: apk list --upgrade
@@ -28,6 +31,3 @@
changed_when: upgrade.stdout is search('nginx')
when: upgrade.stdout is search('nginx')
notify: (Handler) Run NGINX
when:
- nginx_setup == 'upgrade'
- nginx_version is not defined
14 changes: 7 additions & 7 deletions tasks/opensource/install-bsd.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
---
- name: (FreeBSD) Update ports
when:
- ansible_facts['system'] == "FreeBSD"
- nginx_bsd_update_ports | bool
block:
- name: (FreeBSD) Fetch ports
ansible.builtin.command: portsnap fetch --interactive
@@ -10,11 +13,9 @@
ansible.builtin.command: portsnap extract
args:
creates: /usr/ports
when:
- ansible_facts['system'] == "FreeBSD"
- nginx_bsd_update_ports | bool

- name: (FreeBSD) {{ nginx_setup | capitalize }} NGINX
when: ansible_facts['system'] == "FreeBSD"
block:
- name: (FreeBSD) {{ nginx_setup | capitalize }} NGINX package
community.general.pkgng:
@@ -30,9 +31,9 @@
state: "{{ nginx_state }}"
when: not nginx_bsd_install_packages | bool
notify: (Handler) Run NGINX
when: ansible_facts['system'] == "FreeBSD"

- name: (OpenBSD) {{ nginx_setup | capitalize }} NGINX
when: ansible_facts['system'] == "OpenBSD"
block:
- name: (OpenBSD) {{ nginx_setup | capitalize }} NGINX package
community.general.openbsd_pkg:
@@ -49,9 +50,9 @@
state: "{{ nginx_state }}"
when: not nginx_bsd_install_packages | bool
notify: (Handler) Run NGINX
when: ansible_facts['system'] == "OpenBSD"

- name: (NetBSD) {{ nginx_setup | capitalize }} NGINX
when: ansible_facts['system'] == "NetBSD"
block:
- name: (NetBSD) {{ nginx_setup | capitalize }} NGINX package
ansible.builtin.command: pkg_add www/nginx{{ nginx_version | default('') }}
@@ -62,9 +63,9 @@
ansible.builtin.fail:
msg: "{{ ansible_facts['system'] }} {{ nginx_setup | capitalize }} NGINX port not implemented."
when: not nginx_bsd_install_packages | bool
when: ansible_facts['system'] == "NetBSD"

- name: (DragonFlyBSD/HardenedBSD) {{ nginx_setup | capitalize }} NGINX
when: ansible_facts['system'] in ['DragonFlyBSD', 'HardenedBSD']
block:
- name: (DragonFlyBSD/HardenedBSD) {{ nginx_setup | capitalize }} NGINX package
ansible.builtin.command: pkg install www/nginx{{ nginx_version | default('') }}
@@ -75,4 +76,3 @@
ansible.builtin.fail:
msg: "{{ ansible_facts['system'] }} {{ nginx_setup | capitalize }} NGINX port not implemented."
when: not nginx_bsd_install_packages | bool
when: ansible_facts['system'] in ['DragonFlyBSD', 'HardenedBSD']
2 changes: 1 addition & 1 deletion tasks/opensource/install-oss.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
- name: "{{ nginx_setup | capitalize }} NGINX in Linux systems"
when: ansible_facts['system'] | lower is not search('bsd')
block:
- name: "{{ nginx_setup | capitalize }} NGINX from repository"
ansible.builtin.include_tasks: "{{ role_path }}/tasks/opensource/install-{{ ansible_facts['os_family'] | lower }}.yml"
@@ -15,7 +16,6 @@
state: "{{ nginx_state }}"
when: nginx_install_from == "os_repository"
notify: (Handler) Run NGINX
when: ansible_facts['system'] | lower is not search('bsd')

- name: "{{ nginx_setup | capitalize }} NGINX in Unix systems"
ansible.builtin.include_tasks: "{{ role_path }}/tasks/opensource/install-bsd.yml"
Loading