Skip to content

Commit

Permalink
fix: lints
Browse files Browse the repository at this point in the history
  • Loading branch information
jseniuk committed May 31, 2024
1 parent 1e2b44c commit 707ac9d
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 12 deletions.
5 changes: 4 additions & 1 deletion meta/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
---
galaxy_info:
author: Dale Anderson
description: Support logging to a specific file when using the syslog module on a Drupal site
description:
Support logging to a specific file when using the
syslog module on a Drupal site
company: Acro Media Inc.
license: GPLv3
min_ansible_version: 2.6
Expand Down
8 changes: 4 additions & 4 deletions molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,21 +33,21 @@
name: "johndoe"
state: "present"
groups: "sudo"
append: yes
append: true
when: ansible_os_family == 'Debian'

- name: Add system users for RedHat
user:
name: "johndoe"
state: "present"
groups: "wheel"
append: yes
append: true
when: ansible_os_family == 'RedHat'

- name: Install rsyslog

Check warning on line 47 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest

Check warning on line 47 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest

Check warning on line 47 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest
package:
name: rsyslog
state: latest
name: rsyslog
state: latest

- name: Install acl

Check warning on line 52 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest

Check warning on line 52 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest

Check warning on line 52 in molecule/default/converge.yml

View workflow job for this annotation

GitHub Actions / lint

[E403] Package installs should not use latest
package:
Expand Down
2 changes: 1 addition & 1 deletion molecule/default/verify.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
- name: Verify role
hosts: all
become: yes
become: true

vars:
drupal_log_path: /var/log/vhosts/account/project/drupal.log
Expand Down
19 changes: 13 additions & 6 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
copy:
dest: "{{ drupal_log_path }}"
content: ""
force: no
force: false
owner: "{{ syslog_owner }}"
group: "{{ syslog_group }}"
mode: 0640
Expand All @@ -21,7 +21,7 @@
owner: root
group: root
mode: 0644
backup: yes
backup: true
notify: ards restart rsyslog

- name: Configure logrotate for {{ drupal_log_path }}

Check failure on line 27 in tasks/main.yml

View workflow job for this annotation

GitHub Actions / lint

[E404] Doesn't need a relative path in role
Expand All @@ -33,8 +33,12 @@
owner: root
group: root
notify: ards restart rsyslog
# Permissions shouldn't ever need to be re-added to this, since the log file gets copytruncate'd
- name: Give additional ACL permissions on {{ drupal_log_path }} to users specified by drupal_syslog_read_users

# Permissions shouldn't ever need to be re-added to this,
# since the log file gets copytruncate'd
- name:
Give additional ACL permissions on {{ drupal_log_path }}
to users specified by drupal_syslog_read_users
acl:
path: "{{ drupal_log_path }}"
entity: "{{ item }}"
Expand All @@ -46,8 +50,11 @@

# when: drupal_syslog_read_users|length > 0

# Permissions shouldn't ever need to be re-added to this, since the log file gets copytruncate'd
- name: Give additional ACL permissions on {{ drupal_log_path }} to groups specified by drupal_syslog_read_groups
# Permissions shouldn't ever need to be re-added to this,
# since the log file gets copytruncate'd
- name:
Give additional ACL permissions on {{ drupal_log_path }}
to groups specified by drupal_syslog_read_groups
acl:
path: "{{ drupal_log_path }}"
entity: "{{ item }}"
Expand Down

0 comments on commit 707ac9d

Please sign in to comment.