Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Arch Linux
infrastructure
Commits
a4a4f3e7
Verified
Commit
a4a4f3e7
authored
Jun 12, 2020
by
Frederik Schwan
Committed by
Sven-Hendrik Haase
Jun 17, 2020
Browse files
fix E303 'Using command rather than module'
also use systemd instead of service module
parent
fc769a7b
Changes
33
Hide whitespace changes
Inline
Side-by-side
roles/arch32_mirror/handlers/main.yml
deleted
100644 → 0
View file @
fc769a7b
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
roles/arch32_mirror/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -15,13 +15,13 @@
with_items
:
-
syncrepo_arch32.timer
-
syncrepo_arch32.service
notify
:
-
daemon reload
-
name
:
start and enable syncrepo unit
service
:
name={{ item }} enabled=yes state=started
with_items
:
-
syncrepo_arch32.timer
systemd
:
name
:
syncrepo_arch32.timer
enabled
:
yes
state
:
started
daemon_reload
:
yes
-
name
:
make nginx log dir
file
:
path=/var/log/nginx/{{ arch32_mirror_domain }} state=directory owner=root group=root mode=0755
...
...
roles/archbuild/handlers/main.yml
View file @
a4a4f3e7
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
systemd
:
daemon-reload
:
yes
roles/archive/handlers/main.yml
deleted
100644 → 0
View file @
fc769a7b
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
roles/archive/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -73,10 +73,12 @@
loop
:
-
archive-uploader.service
-
archive-uploader.timer
notify
:
-
daemon reload
when
:
not archive_nginx_only
-
name
:
start uploader timer
service
:
name=archive-uploader.timer state=started enabled=yes
systemd
:
name
:
archive-uploader.timer
enabled
:
yes
state
:
started
daemon_reload
:
yes
when
:
not archive_nginx_only
roles/archweb/handlers/main.yml
View file @
a4a4f3e7
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
systemd
:
daemon-reload
:
yes
-
name
:
restart archweb memcached
service
:
name=archweb-memcached state=restarted
roles/archweb/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -257,12 +257,15 @@
when
:
archweb_site and (release.changed or config.changed or virtualenv.changed or archweb_forced_deploy)
notify
:
restart archweb memcached
-
name
:
start and enable archweb memcached service
service
:
name="archweb-memcached.service" enabled=yes state=started
when
:
archweb_site|bool
-
name
:
start and enable archweb rsync iso timer
service
:
name="archweb-rsync_iso.timer" enabled=yes state=started
-
name
:
start and enable archweb memcached service and archweb-rsync_iso timer
systemd
:
name
:
"
{{
item
}}"
enabled
:
yes
state
:
started
daemon_reload
:
yes
with_items
:
-
archweb-memcached.service
-
archweb-rsync_iso.timer
when
:
archweb_site|bool
-
name
:
start and enable archweb reporead service
...
...
@@ -289,12 +292,15 @@
service
:
name="archweb-planet.timer" enabled=yes state=started
when
:
archweb_planet
-
name
:
start and enable archweb donor_import timer
service
:
name="archweb-donor_import.timer" enabled=yes state=started
when
:
archweb_donor_import|bool
-
name
:
start and enable archweb dump donor timer
service
:
name="archweb-dump_donor_mail.timer" enabled=yes state=started
-
name
:
start and enable archweb donor_import and archweb-dump_donor_mail timer
systemd
:
name
:
"
{{
item
}}"
enabled
:
yes
state
:
started
daemon_reload
:
yes
with_items
:
-
archweb-donor_import.timer
-
archweb-dump_donor_mail.timer
when
:
archweb_donor_import|bool
-
name
:
create retro dir
...
...
roles/archwiki/handlers/main.yml
View file @
a4a4f3e7
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
-
name
:
restart php-fpm@archwiki
service
:
name=php-fpm@{{ archwiki_user }} state=restarted
...
...
roles/archwiki/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -97,20 +97,23 @@
-
archwiki-question-updater.service
-
archwiki-memcached.service
-
name
:
start and enable archwiki runjobs timer
service
:
name="archwiki-runjobs.timer" enabled=yes state=started
-
name
:
start and enable archwiki prune cache timer
service
:
name="archwiki-prune-cache.timer" enabled=yes state=started
-
name
:
start and enable archwiki runjobs wait service
service
:
name="archwiki-runjobs-wait.service" enabled=yes state=started
-
name
:
start and enable archwiki timers and services
systemd
:
name
:
"
{{
item
}}"
enabled
:
yes
state
:
started
daemon_reload
:
yes
with_items
:
-
archwiki-runjobs.timer
-
archwiki-prune-cache.timer
-
archwiki-runjobs-wait.service
-
archwiki-memcached.service
-
name
:
create question answer file
s
ervice
:
name=archwiki-question-updater.service state=started
-
name
:
start and enable archwiki memcach
ed
service
:
name=archwiki-memcached.service enabled=yes state=started
s
ystemd
:
name
:
archwiki-question-updater.service
state
:
start
ed
daemon_reload
:
yes
-
name
:
ensure question answer file exists and set permissions
file
:
state=file path="{{ archwiki_question_answer_file }}" owner=root group=root mode=0644
...
...
roles/certbot/handlers/main.yml
deleted
100644 → 0
View file @
fc769a7b
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
roles/certbot/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -14,11 +14,13 @@
with_items
:
-
certbot-renewal.service
-
certbot-renewal.timer
notify
:
-
daemon reload
-
name
:
activate letsencrypt renewal service
service
:
name=certbot-renewal.timer enabled=yes state=started
systemd
:
name
:
certbot-renewal.timer
enabled
:
yes
state
:
started
daemon_reload
:
yes
-
name
:
open firewall holes for certbot standalone authenticator
firewalld
:
service={{ item }} permanent=true state=enabled immediate=yes
...
...
roles/common/handlers/main.yml
View file @
a4a4f3e7
---
-
name
:
restart networkd
service
:
name=systemd-networkd state=restarted
systemd
:
name
:
systemd-networkd
state
:
resarted
daemon_reload
:
yes
-
name
:
restarted journald
service
:
name=systemd-journald state=restarted
-
name
:
restart journald
systemd
:
name
:
systemd-journald
state
:
restarted
daemon_reload
:
yes
-
name
:
systemd daemon-reload
command
:
systemctl daemon-reload
systemd
:
daemon_reload
:
yes
-
name
:
restart syslog-ng
service
:
name=syslog-ng@default state=restarted
...
...
roles/dbscripts/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -201,6 +201,8 @@
become_user
:
svntogit
register
:
git_config_username
changed_when
:
"
git_config_username.rc
==
0"
tags
:
-
skip_ansible_lint
-
name
:
configure svntogit git user email
command
:
git config --global user.name = 'svntogit@repos.archlinux.org'
...
...
@@ -208,6 +210,8 @@
become_user
:
svntogit
register
:
git_config_email
changed_when
:
"
git_config_email.rc
==
0"
tags
:
-
skip_ansible_lint
-
name
:
template arch-svntogit
copy
:
src=update-repos.sh dest=/srv/svntogit/update-repos.sh owner=root group=root mode=0755
...
...
@@ -222,6 +226,8 @@
-
packages
become
:
yes
become_user
:
svntogit
tags
:
-
skip_ansible_lint
-
name
:
add svntogit public remotes
command
:
git remote add public ssh://git.archlinux.org/srv/git/svntogit/{{ item }}.git chdir=/srv/svntogit/repos/{{ item }}
...
...
@@ -233,6 +239,8 @@
ignore_errors
:
yes
register
:
git_public_remote
changed_when
:
"
git_public_remote.rc
==
0"
tags
:
-
skip_ansible_lint
# The following command also serves as a way to get the data the first time the repo is set up
-
name
:
configure svntogit pull upstream branch
...
...
@@ -244,6 +252,8 @@
become_user
:
svntogit
register
:
git_pull_upstream
changed_when
:
"
git_pull_upstream.rc
==
0"
tags
:
-
skip_ansible_lint
-
name
:
configure svntogit push upstream branch
command
:
git push -u public master chdir=/srv/svntogit/repos/{{ item }}
...
...
@@ -254,6 +264,8 @@
become_user
:
svntogit
register
:
git_push_master
changed_when
:
"
git_push_master.rc
==
0"
tags
:
-
skip_ansible_lint
-
name
:
fix svntogit home permissions
file
:
path="/srv/svntogit" state=directory owner=svntogit group=svntogit mode=0775
...
...
roles/docker-image/handlers/main.yml
deleted
100644 → 0
View file @
fc769a7b
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
roles/docker-image/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -16,13 +16,13 @@
-
name
:
install docker_image service
template
:
src='docker-image.service.j2' dest='/etc/systemd/system/docker-image.service' owner=root group=root mode=0644
notify
:
-
daemon reload
-
name
:
install docker_image timer
template
:
src='docker-image.timer.j2' dest='/etc/systemd/system/docker-image.timer' owner=root group=root mode=0644
notify
:
-
daemon reload
-
name
:
start and enable docker_image_build timer
service
:
name='docker-image.timer' enabled=yes state=started
systemd
:
name
:
docker-image.timer
enabled
:
yes
state
:
started
daemon_reload
:
yes
roles/flyspray/handlers/main.yml
deleted
100644 → 0
View file @
fc769a7b
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
-
name
:
restart php-fpm@flyspray
service
:
name=php-fpm@flyspray state=restarted
roles/install_arch/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -54,25 +54,49 @@
dest
:
/tmp/
-
name
:
extract boostrap image
command
:
tar xf archlinux-bootstrap-{{ bootstrap_version }}-x86_64.tar.gz
args
:
chdir
:
/tmp
unarchive
:
src
:
/tmp/archlinux-bootstrap-{{ bootstrap_version }}-x86_64.tar.gz
dest
:
/tmp
creates
:
/tmp/root.x86_64
-
name
:
copy resolv.conf to bootstrap chroot
copy
:
remote_src=True src=/etc/resolv.conf dest=/tmp/root.x86_64/etc/resolv.conf
-
name
:
mount /proc to bootstrap chroot
command
:
mount --rbind /proc /tmp/root.x86_64/proc creates=/tmp/root.x86_64/proc/uptime
mount
:
src
:
/proc
path
:
/tmp/root.x86_64/proc
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
mount /sys to bootstrap chroot
command
:
mount --rbind /sys /tmp/root.x86_64/sys creates=/tmp/root.x86_64/sys/dev
mount
:
src
:
/sys
path
:
/tmp/root.x86_64/sys
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
mount /dev to bootstrap chroot
command
:
mount --rbind /dev /tmp/root.x86_64/dev creates=/tmp/root.x86_64/dev/zero
mount
:
src
:
/dev
path
:
/tmp/root.x86_64/dev
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
mount /mnt to bootstrap chroot
command
:
mount --rbind /mnt /tmp/root.x86_64/mnt creates=/tmp/root.x86_64/mnt/LOCK
mount
:
src
:
/mnt
path
:
/tmp/root.x86_64/mnt
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
configure pacman mirror
template
:
src=mirrorlist.j2 dest=/tmp/root.x86_64/etc/pacman.d/mirrorlist owner=root group=root mode=0644
...
...
@@ -101,13 +125,32 @@
creates
:
/tmp/root.x86_64/mnt/bin
-
name
:
mount /proc to new chroot
command
:
mount --rbind /proc /mnt/proc creates=/mnt/proc/uptime
mount
:
src
:
/proc
path
:
/mnt/proc
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
mount /sys to new chroot
command
:
mount --rbind /sys /mnt/sys creates=/mnt/sys/dev
mount
:
src
:
/sys
path
:
/mnt/sys
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
-
name
:
mount /dev to new chroot
command
:
mount --rbind /dev /mnt/dev creates=/mnt/dev/zero
mount
:
src
:
/dev
path
:
/mnt/dev
opts
:
rbind
state
:
mounted
fstype
:
none
fstab
:
/dev/null
when
:
not stat_result_dev.stat.exists
-
name
:
generate mdadm.conf
shell
:
mdadm --detail --scan >> /mnt/etc/mdadm.conf
...
...
roles/nginx/handlers/main.yml
View file @
a4a4f3e7
...
...
@@ -5,6 +5,3 @@
-
name
:
reload nginx
service
:
name=nginx state=reloaded
-
name
:
daemon reload
command
:
systemctl daemon-reload
roles/patchwork/handlers/main.yml
View file @
a4a4f3e7
---
-
name
:
daemon reload
command
:
systemctl daemon-reload
-
name
:
restart patchwork memcached
service
:
name=patchwork-memcached state=restarted
roles/patchwork/tasks/main.yml
View file @
a4a4f3e7
...
...
@@ -121,8 +121,12 @@
file
:
path=/etc/uwsgi/vassals/patchwork.ini state=touch
when
:
(release.changed or config.changed or virtualenv.changed or patchwork_forced_deploy)
-
name
:
start and enable patchwork memcached service
service
:
name="patchwork-memcached.service" enabled=yes state=started
-
name
:
start and enable patchwork notification timer
service
:
name="patchwork-notification.timer" enabled=yes state=started
-
name
:
start and enable patchwork memcached service and notification timer
systemd
:
name
:
"
{{
item
}}"
enabled
:
yes
state
:
started
daemon_reload
:
yes
with_items
:
-
patchwork-memcached.service
-
patchwork-notification.timer
Prev
1
2
Next
Jakub Klinkovský
@lahwaacz
mentioned in merge request
!51 (closed)
·
Aug 22, 2020
mentioned in merge request
!51 (closed)
mentioned in merge request !51
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment