diff options
author | jaseg <git@jaseg.net> | 2020-12-30 13:12:06 +0100 |
---|---|---|
committer | jaseg <git@jaseg.net> | 2020-12-30 13:12:06 +0100 |
commit | c6b1c2225d1ac4ac647950be8667b5709b0033a1 (patch) | |
tree | 8db7a14649a277d236791e1c731d98af03a0af88 /gerboweb/deploy/setup_gerboweb.yml | |
parent | e290ac758b02a9d03bacd511c87fc997db41d0a8 (diff) | |
download | gerbolyze-c6b1c2225d1ac4ac647950be8667b5709b0033a1.tar.gz gerbolyze-c6b1c2225d1ac4ac647950be8667b5709b0033a1.tar.bz2 gerbolyze-c6b1c2225d1ac4ac647950be8667b5709b0033a1.zip |
remove ansible scripts, they are now in their own "infra" repo
Diffstat (limited to 'gerboweb/deploy/setup_gerboweb.yml')
-rw-r--r-- | gerboweb/deploy/setup_gerboweb.yml | 100 |
1 files changed, 0 insertions, 100 deletions
diff --git a/gerboweb/deploy/setup_gerboweb.yml b/gerboweb/deploy/setup_gerboweb.yml deleted file mode 100644 index 6a20eed..0000000 --- a/gerboweb/deploy/setup_gerboweb.yml +++ /dev/null @@ -1,100 +0,0 @@ ---- -- name: Set local facts - set_fact: - gerboweb_cache: /var/cache/gerboweb - -- name: Copy render script - template: - src: render.sh.j2 - dest: /usr/local/sbin/gerbolyze_render.sh - mode: ug+x - -- name: Copy vector script - template: - src: vector.sh.j2 - dest: /usr/local/sbin/gerbolyze_vector.sh - mode: ug+x - -- name: Install packages into gerbolyze container - shell: arch-chroot "{{gerboweb_root}}" pacman -Syu --noconfirm python3 opencv hdf5 gtk3 python-numpy python-pip imagemagick unzip zip - -- name: Workaround for cairoffi problem - shell: arch-chroot "{{gerboweb_root}}" pip install -U --upgrade-strategy=eager wheel - - # TODO maybe install directly from local git checkout? -- name: Install gerbolyze - shell: arch-chroot "{{gerboweb_root}}" pip install -U --upgrade-strategy=eager gerbolyze - -- name: Copy webapp sources - synchronize: - # FIXME: make this path configurable - src: ~/gerbolyze/gerboweb/ - dest: /var/lib/gerboweb/ - rsync_opts: - - "--exclude=/deploy" - group: no - owner: no - -- name: Create uwsgi worker user and group - user: - name: uwsgi-gerboweb - create_home: no - group: uwsgi - password: '!' - shell: /sbin/nologin - system: yes - -- name: Template webapp config - template: - src: gerboweb.cfg.j2 - dest: /var/lib/gerboweb/gerboweb_prod.cfg - owner: uwsgi-gerboweb - group: root - mode: 0660 - -- name: Copy uwsgi config - copy: - src: uwsgi-gerboweb.ini - dest: /etc/uwsgi.d/gerboweb.ini - owner: uwsgi-gerboweb - group: uwsgi - mode: 0440 - -- name: Copy job processor systemd service config - template: - src: gerboweb-job-processor.service.j2 - dest: /etc/systemd/system/gerboweb-job-processor.service - -- name: Enable uwsgi systemd socket - systemd: - daemon-reload: yes - name: uwsgi-app@gerboweb.socket - enabled: yes - -- name: Copy gerboweb cache dir tmpfiles.d config - template: - src: tmpfiles-gerboweb.conf.j2 - dest: /etc/tmpfiles.d/gerboweb.conf - owner: root - group: root - mode: 0644 - register: tmpfiles_config - -- name: Kick systemd tmpfiles service to create cache dir - command: systemd-tmpfiles --create - when: tmpfiles_config is changed - -- name: Create job queue db - file: - path: "{{gerboweb_cache}}/job_queue.sqlite3" - owner: root - group: uwsgi - mode: 0660 - state: touch - -- name: Enable and launch job processor - systemd: - name: gerboweb-job-processor.service - enabled: yes - state: restarted - |