From ed07d2fad01b286f71ba3c05f64a384cce75677c Mon Sep 17 00:00:00 2001 From: raneq <46573858+raneq@users.noreply.github.com> Date: Wed, 10 Jul 2019 15:37:12 +0200 Subject: [PATCH 1/4] Update main.yml --- defaults/main.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/defaults/main.yml b/defaults/main.yml index 297b09e..3514486 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -6,19 +6,23 @@ odoo_role_odoo_group: odoo # VirtualEnv vars odoo_role_odoo_venv_path: /opt/.odoo_venv -# Edition vars - -# Vars for tar download strategy (or other formats supported by ansible unarchive, i.e. by unzip or gtar) +# Odoo releases download strategy: tar or git odoo_role_download_strategy: tar -odoo_role_odoo_version: 11.0 -odoo_role_odoo_release: 20190501 + +# Vars for tar download strategy +# supported any other formats supported by ansible unarchive, i.e. by unzip or gtar) +# Releases from Odoo.com odoo nightly +odoo_role_odoo_version: 11.0 # not used outside this file +odoo_role_odoo_release: 20190505 # not used outside this file odoo_role_odoo_url: "https://nightly.odoo.com/{{ odoo_role_odoo_version }}/nightly/src/odoo_{{ odoo_role_odoo_version }}.{{ odoo_role_odoo_release }}.tar.gz" +# Releases from an Odoo comunity backports updated fork +# odoo_role_odoo_release: "11.0_2019-05-05" +# odoo_role_odoo_url: "https://gitlab.com/coopdevs/OCB/-/archive/{{ odoo_role_odoo_release }}/OCB-{{ odoo_role_odoo_release }}.tar.gz" odoo_role_odoo_download_path: "{{ odoo_role_odoo_path }}/../odoo_releases/odoo_{{ odoo_role_odoo_version }}.{{ odoo_role_odoo_release }}.tar.gz" -# Vars for the OCA/OCB edition -# odoo_role_download_strategy: git +# Vars for git download strategy odoo_role_odoo_git_url: "https://github.com/OCA/OCB.git" -# OCA/OCB, branch 11.0. LTS probably until 14.0 release. 13.0 is scheduled for October 2019. +# OCA's OCB, branch 11.0. LTS probably until 14.0 release. 13.0 is scheduled for October 2019. odoo_role_odoo_git_ref: "11.0" odoo_role_odoo_path: /opt/odoo From 00568f2eac12e0085cd10ea53ba190dab8333001 Mon Sep 17 00:00:00 2001 From: raneq <46573858+raneq@users.noreply.github.com> Date: Wed, 10 Jul 2019 15:37:59 +0200 Subject: [PATCH 2/4] Update README.md --- README.md | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 6f68791..fceb0a4 100644 --- a/README.md +++ b/README.md @@ -20,21 +20,27 @@ Available variables are listed below, along with default values: * Edition -This role allows to install Odoo in two editions: [Odoo Nightly](http://nightly.odoo.com/) and [OCA/OCB](https://github.com/OCA/OCB.git) edition. +This role supports installing Odoo following two different strategies: `git` (from a git repository) and `tar` (a package or compressed release file). ``` -# Vars for the Odoo Nightly edition -# odoo_role_odoo_edition: "odoo" -odoo_role_odoo_version: 11.0 -odoo_role_odoo_release: 20170914 +# Odoo releases download strategy: tar or git +odoo_role_download_strategy: tar + +# Vars for tar download strategy +# supported any other formats supported by ansible unarchive, i.e. by unzip or gtar) +# Releases from Odoo.com odoo nightly +odoo_role_odoo_version: 11.0 # not used outside this file +odoo_role_odoo_release: 20190505 # not used outside this file odoo_role_odoo_url: "https://nightly.odoo.com/{{ odoo_role_odoo_version }}/nightly/src/odoo_{{ odoo_role_odoo_version }}.{{ odoo_role_odoo_release }}.tar.gz" -odoo_role_odoo_download_path: /tmp/odoo_{{ odoo_role_odoo_version }}.{{ odoo_role_odoo_release }}.tar.gz +# Releases from an Odoo comunity backports updated fork +# odoo_role_odoo_release: "11.0_2019-05-05" +# odoo_role_odoo_url: "https://gitlab.com/coopdevs/OCB/-/archive/{{ odoo_role_odoo_release }}/OCB-{{ odoo_role_odoo_release }}.tar.gz" +odoo_role_odoo_download_path: "{{ odoo_role_odoo_path }}/../odoo_releases/odoo_{{ odoo_role_odoo_version }}.{{ odoo_role_odoo_release }}.tar.gz" -# Vars for the OCA/OCB edition -# odoo_role_odoo_edition: "oca" +# Vars for git download strategy odoo_role_odoo_git_url: "https://github.com/OCA/OCB.git" -# Use the commit SHA of the required version -odoo_role_odoo_head: "8ef3986d58a097a04502d9ca1ee0a860d7230723" +# OCA's OCB, branch 11.0. LTS probably until 14.0 release. 13.0 is scheduled for October 2019. +odoo_role_odoo_git_ref: "11.0" ``` * Users and group From 643102b8d30427a9651f86affd1015c167adcf15 Mon Sep 17 00:00:00 2001 From: raneq <46573858+raneq@users.noreply.github.com> Date: Wed, 10 Jul 2019 18:42:49 +0200 Subject: [PATCH 3/4] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index fceb0a4..514b0de 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,7 @@ Example Playbook vars: odoo_role_odoo_db_name: odoo-db odoo_role_odoo_db_admin_password: "{{ odoo_admin_password }}" + odoo_role_download_strategy: tar odoo_role_odoo_version: 11.0 odoo_role_odoo_release: 20180424 ``` From 769834b8dcf36804a1f62aa7f729eebb5d824d0a Mon Sep 17 00:00:00 2001 From: raneq <46573858+raneq@users.noreply.github.com> Date: Wed, 10 Jul 2019 21:20:10 +0200 Subject: [PATCH 4/4] Tag code blocks with yaml syntax --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 514b0de..451ff45 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ Available variables are listed below, along with default values: This role supports installing Odoo following two different strategies: `git` (from a git repository) and `tar` (a package or compressed release file). -``` +```yml # Odoo releases download strategy: tar or git odoo_role_download_strategy: tar @@ -45,7 +45,7 @@ odoo_role_odoo_git_ref: "11.0" * Users and group -``` +```yml odoo_role_odoo_user: odoo odoo_role_odoo_group: odoo @@ -55,7 +55,7 @@ odoo_role_odoo_venv_path: /opt/.odoo_venv * Directories structure -``` +```yml odoo_role_odoo_path: /opt/odoo odoo_role_odoo_bin_path: "{{ odoo_role_odoo_path }}/build/scripts-2.7/odoo" odoo_role_odoo_python_path: "{{ odoo_venv_path }}/bin/python" @@ -66,7 +66,7 @@ odoo_role_odoo_modules_path: /opt/odoo/modules * Database -``` +```yml odoo_role_odoo_db_name: odoo # This not a DB user password, but a password for Odoo to deal with DB. odoo_role_odoo_db_admin_password: 1234 @@ -76,14 +76,14 @@ odoo_role_demo_data: false * Core modules list to install/update -``` +```yml # Comma-separated list of modules to install before running the server odoo_role_odoo_core_modules: "base" ``` * Community modules list to install/update -``` +```yml # Comma-separated list of modules to install before running the server odoo_role_odoo_community_modules: "" ``` @@ -111,7 +111,7 @@ Once the modules are in the server, you need to install them in the database. Define a `odoo_role_odoo_community_modules` var with the list of the modules names you want to install. -``` +```yml # invenotry/group_vars/all.yml odoo_role_odoo_community_modules: 'contract,contract_sale_invoicing' ```