1
1
Fork 0
mirror of https://gitlab.archlinux.org/archlinux/infrastructure.git synced 2024-06-19 17:08:58 +02:00

roles/patchwork: Syncdb task removal and notification timer and service addition

The syncdb command was removed on django 1.9, and we can't use it for the initial
database migration. Also, add tasks for installing the notification timer and service
units and enable the timer unit.
This commit is contained in:
Giancarlo Razzolini 2017-08-23 15:32:48 -03:00
parent 730f0b66f0
commit 1e0bc7aeea
No known key found for this signature in database
GPG Key ID: F22FB1D78A77AEAB

View File

@ -52,12 +52,6 @@
postgresql_db: name="{{ patchwork_db }}" login_host="{{ patchwork_db_host }}" login_password="{{ postgres_users.postgres }}" owner="{{ patchwork_db_user }}"
register: db_created
- name: django syncdb
django_manage: app_path="{{ patchwork_dir }}" command=syncdb virtualenv="{{ patchwork_dir }}/env"
become: true
become_user: patchwork
when: db_created.changed
- name: django migrate
django_manage: app_path="{{ patchwork_dir }}" command=migrate virtualenv="{{ patchwork_dir }}/env"
become: true
@ -93,6 +87,16 @@
notify:
- daemon reload
- name: install patchwork notification service
template: src="patchwork-notification.service.j2" dest="/etc/systemd/system/patchwork-notification.service" owner=root group=root mode=0644
notify:
- daemon reload
- name: install patchwork notification timer
template: src="patchwork-notification.timer.j2" dest="/etc/systemd/system/patchwork-notification.timer" owner=root group=root mode=0644
notify:
- daemon reload
- name: deploy patchwork
template: src=patchwork.ini.j2 dest=/etc/uwsgi/vassals/patchwork.ini owner=patchwork group=http mode=0644
@ -104,3 +108,6 @@
- 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