mangono-addon-odoo_custom_server
odoo-bin commands to run Odoo in a cloud environment: web server behind an integrated reverse proxy, automatic
module update on deployment, database neutralization, assets regeneration, interactive shell. The configuration
comes from the environment variables, through environ-odoo-config,
without an odoo.conf file.
The package ships the Odoo module odoo_custom_server. It is not installed on a database: it only provides the
commands and the patches of the Odoo core they apply at startup. Odoo itself is not modified.
- Source code: gitlab.mangono.io/odoo-cloud/server-command
- Documentation: odoo-cloud.docs.mangono.io/server-command (Mangono account required)
Installation
pip install mangono-addon-odoo_custom_server
Install it in the Python environment of Odoo. The commands are then available as odoo-bin <command>.
Supported versions: Odoo 14 to 20, tested in CI on each of them.
Commands
| Command | Role |
|---|---|
cloud_server |
Odoo web server behind a Caddy reverse proxy started and stopped with Odoo: static files, X-Sendfile, database manager blocking. |
cloud_auto_update |
Installs and updates the modules, then stops. Detects the installed modules that changed (manifest version or content hash). |
generate_assets |
Removes the asset bundles of a database (rebuilt by Odoo at the next request) and computes the missing menu icons. |
db_neutralize |
Neutralizes a database like odoo-bin neutralize, then runs the dump-cleaner.sql of each addons path. |
cloud_shell |
Interactive shell with the options of the Odoo 20 odoo-bin shell (--shell-interface, --shell-file), on Odoo 14 to 20. |
front_proxy |
Starts or stops the Caddy reverse proxy apart from the Odoo process (start / stop). |
Deprecated, removed in 2.0.0: generic_server, web_server (replaced by cloud_server), update_server (replaced
by cloud_auto_update).
Usage
# Web server on $HTTP_PORT, Odoo listens on 127.0.0.1:8069 behind Caddy
DB_NAME=my_db odoo-bin cloud_server
# Install $INSTALL, update $UPDATE and the modules changed since the last update, then stop
DB_NAME=my_db odoo-bin cloud_auto_update
# Other commands
DB_NAME=my_db odoo-bin generate_assets
DB_NAME=my_db odoo-bin db_neutralize
DB_NAME=my_db odoo-bin cloud_shell --shell-interface ipython
cloud_auto_update takes a PostgreSQL advisory lock per database: several instances started together do not update
the same database in parallel.
Odoo core patches
Applied at startup by the commands of this package, through runtime wrappers (wrapt):
- Database allow-list: Odoo connects only to the databases of
$DB_NAME. A connection topostgresis redirected to the first configured database, any other database is refused. - PostgreSQL
application_name:odoo-<pid>by default, orPGAPPNAME/db_app_name({pid}is replaced). - Reverse proxy:
X-Forwarded-Hostis set fromHostwhen the proxy sends onlyX-Forwarded-Proto(case of Clever Cloud), so that Odoo stays in proxy mode. - Garbage collector: the thresholds of Odoo 19 on Odoo 14 to 18 (
GC_THRESHOLDto override),gc.freeze()before each worker fork in prefork mode (GC_FREEZE=Falseto disable). - HTTP
Serverheader:Odooinstead of the Werkzeug and Python versions.
Security
- The database allow-list applies only when
$DB_NAMEis set. Without it, Odoo connects to any database, as usual. - With
cloud_server, Odoo listens on127.0.0.1only; only the proxy is exposed. - With
cloud_server, the/web/database/*routes are redirected to/web/loginby the proxy whenlist_dbis off (LIST_DB). When it is on, the database manager is reachable, protected by the Odoo master password only. - The other commands (
odoo-binwithout proxy) do not block the database manager.
License
Metadata
Release files for mangono-addon-odoo-custom-server 1.8.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mangono_addon_odoo_custom_server-1.8.3.tar.gz | 114.3 kB | Without provenance | Details for mangono_addon_odoo_custom_server-1.8.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mangono_addon_odoo_custom_server-1.8.3-py3-none-any.whl | Python 3 | none | any | Details for mangono_addon_odoo_custom_server-1.8.3-py3-none-any.whl |
Total release size: 164.3 kB
Release files / mangono_addon_odoo_custom_server-1.8.3.tar.gz
| Download URL | mangono_addon_odoo_custom_server-1.8.3.tar.gz |
|---|---|
| Size | 114.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a5a431cd907a12d63f2129f0eb2b8eb34aee5a3bac5787669801836351007685
|
|
BLAKE2b-256 checksum How to use checksums |
9527794cfb5c54ed65492401156ddd9f4377c6a0ddbd3b87d89e9e373bdc83f4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.15.2
|
Release files / mangono_addon_odoo_custom_server-1.8.3-py3-none-any.whl
| Download URL | mangono_addon_odoo_custom_server-1.8.3-py3-none-any.whl |
|---|---|
| Size | 50.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
637021dfd8c48883fe375a432af9617a61004e4fa48824169b9c301a814a65ad
|
|
BLAKE2b-256 checksum How to use checksums |
b9c1d0afaa2ae8b004dc42eb51ae04072d42041757c13e8ca4dd19e3a13e001b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.15.2
|
Security for mangono-addon-odoo-custom-server 1.8.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.