123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100 |
- ---
- - name: Dependencies installed
- community.general.pkgng:
- name: py39-pip,py39-lxml,py39-gunicorn,bash,yarn-node18,git-tiny,npm-node18,rust
- state: latest
- - name: Source folder exists
- file:
- path: /usr/local/src
- owner: root
- mode: 0755
- state: directory
- - name: Wger source @ master
- git:
- repo: "https://github.com/wger-project/wger.git"
- dest: /usr/local/src/wger
- update: yes
- force: yes
- tags:
- - update
- - name: Wger requirements up to date
- pip:
- requirements: /usr/local/src/wger/requirements.txt
- executable: pip
- - name: sass installed
- shell:
- cmd: npm install -g sass
- tags:
- - update
- - name: Wger UI built
- shell:
- cmd: yarn && yarn install
- chdir: /usr/local/src/wger/
- tags:
- - update
- - name: Wger UI built
- shell:
- cmd: yarn build:css:sass
- chdir: /usr/local/src/wger/
- tags:
- - update
- - name: Media directory exists
- file:
- path: /usr/local/www/wger/static/
- mode: 0755
- state: directory
- - name: Static directory exists
- file:
- path: /usr/local/www/wger/media
- mode: 0755
- state: directory
- - name: Wger conf file installed
- template:
- src: settings.py.j2
- dest: /usr/local/src/wger/settings.py
- owner: root
- mode: 0644
- - name: Wger db migrated
- shell:
- cmd: python3.9 manage.py migrate
- chdir: /usr/local/src/wger/
- tags:
- - update
- - name: Wger static files collected
- shell:
- cmd: python3.9 manage.py collectstatic --noinput
- chdir: /usr/local/src/wger/
- tags:
- - update
- - name: Wger permissions updated
- shell:
- cmd: python3.9 manage.py loaddata groups.json categories.json
- chdir: /usr/local/src/wger/
- tags:
- - update
- - name: Wger nginx file installed
- copy:
- src: nginx-location.conf
- dest: /usr/local/etc/nginx/locations/wger.conf
- mode: 0644
- notify: Nginx restarted
- - name: Wger immortal file installed
- copy:
- src: immortal-wger.yml
- dest: /usr/local/etc/immortal/wger.yml
- mode: 0644
- notify: Immortal restarted
|