Release of EvoBSD 6.8.0 #37
|
@ -29,17 +29,32 @@
|
|||
- etc-git
|
||||
- commit-etc
|
||||
|
||||
# yamllint disable rule:line-length
|
||||
- name: set commit author
|
||||
set_fact:
|
||||
commit_author: '{% if ansible_env.SUDO_USER is not defined %}root{% else %}{{ ansible_env.SUDO_USER }}{% endif %}'
|
||||
commit_email: '{% if git_config_user_email.config_value is not defined or git_config_user_email.config_value == "" %}root@localhost{% else %}{{ git_config_user_email.config_value }}{% endif %}'
|
||||
commit_author: >
|
||||
{% if ansible_env.SUDO_USER is not defined %}
|
||||
root
|
||||
{% else %}
|
||||
{{ ansible_env.SUDO_USER }}
|
||||
{% endif %}
|
||||
commit_email: >
|
||||
{% if git_config_user_email.config_value is not defined
|
||||
or git_config_user_email.config_value == "" %}
|
||||
root@localhost
|
||||
{% else %}
|
||||
{{ git_config_user_email.config_value }}
|
||||
{% endif %}
|
||||
tags:
|
||||
- etc-git
|
||||
- commit-etc
|
||||
|
||||
- name: /etc modifications are committed
|
||||
shell: "git add -A . && git commit -m \"{{ commit_message | mandatory }}\" --author \"{{ commit_author | mandatory }} <{{ commit_email | mandatory }}>\""
|
||||
shell: >
|
||||
git add -A .
|
||||
&& git commit
|
||||
-m "{{ commit_message | mandatory }}"
|
||||
--author
|
||||
"{{ commit_author | mandatory }} <{{ commit_email | mandatory }}>"
|
||||
args:
|
||||
chdir: /etc
|
||||
register: etc_commit_end_run
|
||||
|
@ -48,7 +63,6 @@
|
|||
tags:
|
||||
- etc-git
|
||||
- commit-etc
|
||||
# yamllint enable rule:line-length
|
||||
|
||||
- debug:
|
||||
var: etc_commit_end_run
|
||||
|
|
Loading…
Reference in a new issue