diff --git a/.travis.yml b/.travis.yml index 6ab6f94..2d3d67c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -33,6 +33,10 @@ env: - IMAGE="images:debian/stretch" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=standard ANSIBLE_VERSION="2.4,<2.5" - IMAGE="images:debian/stretch" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=buildout ANSIBLE_VERSION="2.4,<2.5" - IMAGE="images:debian/stretch" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=pip ANSIBLE_VERSION="2.4,<2.5" + # Odoo 12.0 + - IMAGE="images:debian/stretch" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=standard ANSIBLE_VERSION="2.4,<2.5" + - IMAGE="images:debian/stretch" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=buildout ANSIBLE_VERSION="2.4,<2.5" + - IMAGE="images:debian/stretch" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=pip ANSIBLE_VERSION="2.4,<2.5" # Ubuntu 14.04 (trusty) # Odoo 8.0 - IMAGE="ubuntu:trusty" ODOO_VERSION=8.0 ODOO_INSTALL_TYPE=standard ANSIBLE_VERSION="2.4,<2.5" @@ -63,6 +67,10 @@ env: - IMAGE="ubuntu:xenial" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=standard ANSIBLE_VERSION="2.4,<2.5" - IMAGE="ubuntu:xenial" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=buildout ANSIBLE_VERSION="2.4,<2.5" - IMAGE="ubuntu:xenial" ODOO_VERSION=11.0 ODOO_INSTALL_TYPE=pip ANSIBLE_VERSION="2.4,<2.5" + # Odoo 12.0 + - IMAGE="ubuntu:xenial" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=standard ANSIBLE_VERSION="2.4,<2.5" + - IMAGE="ubuntu:xenial" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=buildout ANSIBLE_VERSION="2.4,<2.5" + - IMAGE="ubuntu:xenial" ODOO_VERSION=12.0 ODOO_INSTALL_TYPE=pip ANSIBLE_VERSION="2.4,<2.5" install: # Spawn a LXD container diff --git a/README.md b/README.md index f4e1db4..17f985b 100644 --- a/README.md +++ b/README.md @@ -25,12 +25,12 @@ Minimum Ansible Version: 2.4 ## Supported versions and systems -| System / Odoo | 8.0 | 9.0 | 10.0 | 11.0 | -|---------------|-----|-----|------|------| -| Debian 8 | yes | yes | yes | - | -| Debian 9 | yes | yes | yes | yes | -| Ubuntu 14.04 | yes | yes | yes | - | -| Ubuntu 16.04 | yes | yes | yes | yes | +| System / Odoo | 8.0 | 9.0 | 10.0 | 11.0 | 12.0 | +|---------------|-----|-----|------|------|------| +| Debian 8 | yes | yes | yes | - | - | +| Debian 9 | yes | yes | yes | yes | yes | +| Ubuntu 14.04 | yes | yes | yes | - | - | +| Ubuntu 16.04 | yes | yes | yes | yes | - | ## Example (Playbook) @@ -45,7 +45,7 @@ the same host): become: yes roles: - role: odoo - odoo_version: 11.0 + odoo_version: 12.0 odoo_config_admin_passwd: SuPerPassWorD ``` @@ -61,7 +61,7 @@ available from your Ansible inventory): become: yes roles: - role: odoo - odoo_version: 11.0 + odoo_version: 12.0 odoo_config_admin_passwd: SuPerPassWorD odoo_config_db_host: pg_server odoo_config_db_user: odoo @@ -87,7 +87,7 @@ Here we set some options required by the ``connector`` framework: become: yes roles: - role: odoo - odoo_version: 11.0 + odoo_version: 12.0 odoo_repo_type: git odoo_repo_url: https://SERVER/REPO odoo_repo_rev: master @@ -109,7 +109,7 @@ Here we set some options required by the ``connector`` framework: Pip installation (assuming that PostgreSQL is installed and running on the same host). We need to ensure that the environment variable LC_ALL is used -if Odoo version 11 is to be used: +if Odoo version 12 is to be used: ```yaml - name: Odoo @@ -118,8 +118,8 @@ if Odoo version 11 is to be used: roles: - role: odoo odoo_install_type: pip - odoo_version: 11.0 - odoo_pip_requirements_url: https://raw.githubusercontent.com/OCA/sample-oca-pip-requirements/11.0/requirements.txt + odoo_version: 12.0 + odoo_pip_requirements_url: https://raw.githubusercontent.com/OCA/sample-oca-pip-requirements/12.0/requirements.txt odoo_config_admin_passwd: SuPerPassWorD environment: LC_ALL: en_US.UTF-8 @@ -139,7 +139,7 @@ by Buildout: roles: - role: odoo odoo_install_type: buildout - odoo_version: 11.0 + odoo_version: 12.0 odoo_repo_type: git odoo_repo_url: https://github.com/osiell/odoo-buildout-example.git odoo_repo_rev: "{{ odoo_version }}" @@ -156,7 +156,7 @@ your Ansible inventory): roles: - role: odoo odoo_install_type: buildout - odoo_version: 11.0 + odoo_version: 12.0 odoo_repo_type: git odoo_repo_url: https://github.com/osiell/odoo-buildout-example.git odoo_repo_rev: "{{ odoo_version }}" @@ -191,7 +191,7 @@ We just set the relevant options to tell Ansible the files to use with the roles: - role: odoo odoo_install_type: buildout - odoo_version: 11.0 + odoo_version: 12.0 odoo_repo_type: git odoo_repo_url: https://SERVER/REPO odoo_repo_rev: master diff --git a/defaults/main.yml b/defaults/main.yml index c270c5c..2861c01 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,7 +1,7 @@ ansible_ssh_pipelining: true odoo_install_type: standard # standard, buildout -odoo_version: 11.0 +odoo_version: 12.0 odoo_service: odoo odoo_user: odoo odoo_user_passwd: "*" # http://docs.ansible.com/ansible/latest/reference_appendices/faq.html#how-do-i-generate-crypted-passwords-for-the-user-module diff --git a/templates/odoo-12.0-pip-requirements.txt b/templates/odoo-12.0-pip-requirements.txt new file mode 100644 index 0000000..4bd4f34 --- /dev/null +++ b/templates/odoo-12.0-pip-requirements.txt @@ -0,0 +1,2 @@ +https://nightly.odoo.com/12.0/nightly/src/odoo_12.0.latest.zip +-e git+https://github.com/OCA/server-ux.git@12.0#egg=odoo12_addon_date_range&subdirectory=setup/date_range diff --git a/templates/odoo-12.0.conf b/templates/odoo-12.0.conf new file mode 100644 index 0000000..bf2ff64 --- /dev/null +++ b/templates/odoo-12.0.conf @@ -0,0 +1,65 @@ +[options] +{% if odoo_install_type == 'pip' %} +addons_path = +{% else %} +addons_path = {{ odoo_config_addons_path.__class__.__name__ == 'list' and odoo_config_addons_path | join(',') or odoo_config_addons_path }} +{% endif %} +admin_passwd = {{ odoo_config_admin_passwd }} +csv_internal_sep = {{ odoo_config_csv_internal_sep }} +data_dir = {{ odoo_config_data_dir }} +db_host = {{ odoo_config_db_host not in [False, 'localhost', '127.0.0.1'] and odoo_config_db_host in hostvars and hostvars[odoo_config_db_host].get('ansible_host') or odoo_config_db_host }} +db_maxconn = {{ odoo_config_db_maxconn }} +db_name = {{ odoo_config_db_name }} +db_password = {{ odoo_config_db_passwd }} +db_port = {{ odoo_config_db_port }} +db_sslmode = {{ odoo_config_db_sslmode }} +db_template = {{ odoo_config_db_template }} +db_user = {{ odoo_config_db_user }} +dbfilter = {{ odoo_config_dbfilter }} +demo = {} +email_from = {{ odoo_config_email_from }} +geoip_database = {{ odoo_config_geoip_database }} +http_enable = {{ odoo_config_http_enable or odoo_config_xmlrpc }} +http_interface = {{ odoo_config_http_interface or odoo_config_xmlrpc_interface }} +http_port = {{ odoo_config_http_port or odoo_config_xmlrpc_port }} +import_partial = +limit_memory_hard = {{ odoo_config_limit_memory_hard }} +limit_memory_soft = {{ odoo_config_limit_memory_soft }} +limit_request = 8192 +limit_time_cpu = {{ odoo_config_limit_time_cpu }} +limit_time_real = {{ odoo_config_limit_time_real }} +limit_time_real_cron = {{ odoo_config_limit_time_real_cron }} +list_db = {{ odoo_config_list_db }} +log_db = {{ odoo_config_log_db }} +log_db_level = warning +log_handler = :INFO +log_level = {{ odoo_config_log_level }} +logfile = {{ odoo_config_logfile }} +logrotate = {{ odoo_config_logrotate }} +longpolling_port = {{ odoo_config_longpolling_port }} +max_cron_threads = {{ odoo_config_max_cron_threads }} +osv_memory_age_limit = {{ odoo_config_osv_memory_age_limit }} +osv_memory_count_limit = {{ odoo_config_osv_memory_count_limit }} +pg_path = None +pidfile = {{ odoo_config_pidfile }} +proxy_mode = {{ odoo_config_proxy_mode }} +reportgz = False +server_wide_modules = {{ odoo_config_server_wide_modules }} +smtp_password = {{ odoo_config_smtp_password }} +smtp_port = {{ odoo_config_smtp_port }} +smtp_server = {{ odoo_config_smtp_server }} +smtp_ssl = {{ odoo_config_smtp_ssl }} +smtp_user = {{ odoo_config_smtp_user }} +syslog = {{ odoo_config_syslog }} +test_commit = False +test_enable = False +test_file = False +test_report_directory = False +translate_modules = {{ odoo_config_translate_modules }} +unaccent = {{ odoo_config_unaccent }} +without_demo = {{ odoo_config_without_demo }} +workers = {{ odoo_config_workers }} +{% for name in odoo_config_custom | sort %} +{{ name }} = {{ odoo_config_custom[name] }} +{% endfor %} + diff --git a/templates/odoo-12.0.init b/templates/odoo-12.0.init new file mode 120000 index 0000000..5cb1712 --- /dev/null +++ b/templates/odoo-12.0.init @@ -0,0 +1 @@ +odoo-10.0.init \ No newline at end of file diff --git a/vars/Debian-10_Odoo-12.yml b/vars/Debian-10_Odoo-12.yml new file mode 100644 index 0000000..bacd3dc --- /dev/null +++ b/vars/Debian-10_Odoo-12.yml @@ -0,0 +1,103 @@ +--- + +odoo_debian_packages: + - python3-dev + - python3-openssl + - python3-markupsafe + # Dependencies taken from the deb package + - python3-babel + - python3-chardet + - python3-dateutil + - python3-decorator + - python3-docutils + - python3-feedparser + - python3-gevent + - python3-html2text + - python3-jinja2 + - python3-libsass + - python3-lxml + - python3-mako + - python3-mock + - python3-ofxparse + - python3-passlib + - python3-pil + - python3-psutil + - python3-psycopg2 + - python3-pydot + - python3-pyldap + - python3-pyparsing + - python3-pypdf2 + - python3-qrcode + - python3-reportlab + - python3-requests + - python3-serial + - python3-suds + - python3-tz + - python3-usb + - python3-vatnumber + - python3-vobject + - python3-werkzeug + - python3-xlsxwriter + +odoo_nodejs_apt_package: "nodejs=6.*" +odoo_nodejs_apt_repo: "node_6.x" +odoo_npm_packages: + - name: less + version: 2.7.2 + - name: less-plugin-clean-css + version: 1.5.1 + - name: phantomjs-prebuilt + version: 2.1.15 + +odoo_pip_dependencies: + - wrapt + - setuptools-odoo + - odoo-autodiscover + +odoo_pip_build_dependencies: + - python3-virtualenv + - build-essential + - python3-dev + - libxml2-dev + - libxslt1-dev + - libpq-dev + - libldap2-dev + - libsasl2-dev + - libopenjp2-7-dev + - libjpeg62-turbo-dev + - libtiff5-dev + - libfreetype6-dev + - liblcms2-dev + - libwebp-dev + - libssl-dev + +odoo_buildout_build_dependencies: + - virtualenv + - build-essential + - python3-dev + - libxml2-dev + - libxslt1-dev + - libpq-dev + - libldap2-dev + - libsasl2-dev + - libopenjp2-7-dev + - libjpeg62-turbo-dev + - libtiff5-dev + - libfreetype6-dev + - liblcms2-dev + - libwebp-dev + +odoo_buildout_venv_cmd: "python3 -m virtualenv --no-setuptools --python=python3 {{ odoo_buildout_venv_path }}" +odoo_pip_venv_cmd: "python3 -m virtualenv --python=python3 {{ odoo_pip_venv_path }}" + +odoo_wkhtmltox_version: 0.12.5 + +odoo_wkhtmltox_depends: + - fontconfig + - libfontconfig1 + - libfreetype6 + - zlib1g + - libx11-6 + - libxext6 + - libxrender1 + - libjpeg62-turbo diff --git a/vars/Debian-9_Odoo-12.yml b/vars/Debian-9_Odoo-12.yml new file mode 100644 index 0000000..bacd3dc --- /dev/null +++ b/vars/Debian-9_Odoo-12.yml @@ -0,0 +1,103 @@ +--- + +odoo_debian_packages: + - python3-dev + - python3-openssl + - python3-markupsafe + # Dependencies taken from the deb package + - python3-babel + - python3-chardet + - python3-dateutil + - python3-decorator + - python3-docutils + - python3-feedparser + - python3-gevent + - python3-html2text + - python3-jinja2 + - python3-libsass + - python3-lxml + - python3-mako + - python3-mock + - python3-ofxparse + - python3-passlib + - python3-pil + - python3-psutil + - python3-psycopg2 + - python3-pydot + - python3-pyldap + - python3-pyparsing + - python3-pypdf2 + - python3-qrcode + - python3-reportlab + - python3-requests + - python3-serial + - python3-suds + - python3-tz + - python3-usb + - python3-vatnumber + - python3-vobject + - python3-werkzeug + - python3-xlsxwriter + +odoo_nodejs_apt_package: "nodejs=6.*" +odoo_nodejs_apt_repo: "node_6.x" +odoo_npm_packages: + - name: less + version: 2.7.2 + - name: less-plugin-clean-css + version: 1.5.1 + - name: phantomjs-prebuilt + version: 2.1.15 + +odoo_pip_dependencies: + - wrapt + - setuptools-odoo + - odoo-autodiscover + +odoo_pip_build_dependencies: + - python3-virtualenv + - build-essential + - python3-dev + - libxml2-dev + - libxslt1-dev + - libpq-dev + - libldap2-dev + - libsasl2-dev + - libopenjp2-7-dev + - libjpeg62-turbo-dev + - libtiff5-dev + - libfreetype6-dev + - liblcms2-dev + - libwebp-dev + - libssl-dev + +odoo_buildout_build_dependencies: + - virtualenv + - build-essential + - python3-dev + - libxml2-dev + - libxslt1-dev + - libpq-dev + - libldap2-dev + - libsasl2-dev + - libopenjp2-7-dev + - libjpeg62-turbo-dev + - libtiff5-dev + - libfreetype6-dev + - liblcms2-dev + - libwebp-dev + +odoo_buildout_venv_cmd: "python3 -m virtualenv --no-setuptools --python=python3 {{ odoo_buildout_venv_path }}" +odoo_pip_venv_cmd: "python3 -m virtualenv --python=python3 {{ odoo_pip_venv_path }}" + +odoo_wkhtmltox_version: 0.12.5 + +odoo_wkhtmltox_depends: + - fontconfig + - libfontconfig1 + - libfreetype6 + - zlib1g + - libx11-6 + - libxext6 + - libxrender1 + - libjpeg62-turbo