Switch some shell commands to file for idempotency
This commit is contained in:
parent
ac7673efb8
commit
e2f2a0fd52
1 changed files with 2 additions and 2 deletions
|
@ -36,14 +36,14 @@
|
|||
# shell: chown -R copr-service:copr-service /var/log/copr-dist-git
|
||||
|
||||
- name: make sure directories are owned by copr-service user
|
||||
shell: chown copr-service:copr-service {{ item }}
|
||||
file: path={{ item }} owner=copr-service group=copr-service
|
||||
with_items:
|
||||
- /var/lib/copr-dist-git/
|
||||
- /var/lib/copr-dist-git/cgit_pkg_list
|
||||
- /var/log/copr-dist-git
|
||||
|
||||
- name: make sure directories are owned by copr-service:packager user
|
||||
shell: stat -c '%U' /var/lib/dist-git/git | grep copr-service || stat -c '%G' /var/lib/dist-git/git |grep packager || chown -R copr-service:packager /var/lib/dist-git/git
|
||||
file: path=/var/lib/dist-git/git owner=copr-service group=packager recurse=yes
|
||||
|
||||
# set ssh key, so that copr-service could access gitolite
|
||||
- name: read pub key into var
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue