mirror of
https://git.lapiole.org/dani/ansible-roles.git
synced 2025-07-29 10:45:42 +02:00
Update to 2023-07-20 14:00
This commit is contained in:
@@ -6,29 +6,36 @@
|
||||
|
||||
- when: odoo_install_mode != 'none'
|
||||
block:
|
||||
- name: Fetch odoo sources
|
||||
get_url:
|
||||
url: "{{ odoo_archive_url }}"
|
||||
dest: "{{ odoo_root_dir }}/tmp"
|
||||
checksum: sha256:{{ odoo_archive_sha256 }}
|
||||
- name: Clone or update the repo
|
||||
git:
|
||||
repo: "{{ odoo_git_url }}"
|
||||
dest: "{{ odoo_root_dir }}/app"
|
||||
depth: 1
|
||||
version: "{{ odoo_version }}"
|
||||
force: True
|
||||
notify: restart odoo-server
|
||||
|
||||
- name: Extract odoo archive
|
||||
unarchive:
|
||||
src: "{{ odoo_root_dir }}/tmp/odoo_{{ odoo_version }}.{{ odoo_build }}.tar.gz"
|
||||
dest: "{{ odoo_root_dir }}/tmp"
|
||||
remote_src: True
|
||||
|
||||
- name: Copy odoo application to its final directory
|
||||
synchronize:
|
||||
src: "{{ odoo_root_dir }}/tmp/odoo-{{ odoo_version }}.post{{ odoo_build }}/"
|
||||
dest: "{{ odoo_root_dir }}/app/"
|
||||
recursive: True
|
||||
delete: True
|
||||
compress: False
|
||||
delegate_to: "{{ inventory_hostname }}"
|
||||
- name: Add ACL
|
||||
command: |
|
||||
setfacl -R -b -k {{ odoo_root_dir }}
|
||||
setfacl -m u:nginx:X {{ odoo_root_dir }}
|
||||
setfacl -R -m u:nginx:rX {{ odoo_root_dir }}/data {{ odoo_root_dir }}/app/addons {{ odoo_root_dir }}/app/odoo/addons {{ odoo_root_dir }}/enterprise
|
||||
|
||||
tags: odoo
|
||||
|
||||
- when: odoo_install_mode != 'none' and odoo_enterprise
|
||||
block:
|
||||
- name: Clone or update the enterprise repo
|
||||
git:
|
||||
repo: "{{ odoo_enterprise_git_url }}"
|
||||
dest: "{{ odoo_root_dir }}/enterprise"
|
||||
depth: 1
|
||||
version: "{{ odoo_version }}"
|
||||
force: True
|
||||
notify: restart odoo-server
|
||||
tags: odoo
|
||||
|
||||
|
||||
- name: Create the virtualenv
|
||||
pip:
|
||||
state: "{{ (odoo_install_mode == 'none') | ternary('present', 'latest') }}"
|
||||
@@ -36,7 +43,7 @@
|
||||
virtualenv_command: "{{ odoo_venv_command }}"
|
||||
requirements: "{{ odoo_root_dir }}/app/requirements.txt"
|
||||
environment:
|
||||
PATH: "{{ (pg_version == 'default') | ternary('', '/usr/pgsql-' ~ pg_version ~ '/bin:') }}/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
|
||||
PATH: "{{ (pg_version | default('default') == 'default') | ternary('', '/usr/pgsql-' ~ pg_version ~ '/bin:') }}/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
|
||||
tags: odoo
|
||||
|
||||
- name: Install additional modules in the venv
|
||||
|
Reference in New Issue
Block a user