Skip to content

Deployment Overview of Odoo on Server

Prerequisites and Basic Requirements

To ensure a successful deployment, the following requirements must be met:

  • Operating System: Debian or Ubuntu (including version 24.04).

  • Privileges: Root or sudo access is required for package installation and configuration changes.

  • Ports:

  • 80 (HTTP) for initial connection and SSL challenges.

  • 443 (HTTPS) for secure web traffic.

  • 8069 (Internal) used by the application service.

FQDN of the final panel on the hostkey.in domain

The access URL is generated based on a specific template using the server's unique identifier.

Parameter Value
Prefix odoo
Domain hostkey.in
Full template odoo{Server_ID}.hostkey.in

File and Directory Structure

The following directories are used for configuration and data management:

  • /root/nginx: Contains the Docker Compose configuration for the Nginx proxy.

  • /data/nginx/user_conf.d: Stores the Nginx server configuration files.

  • /data/nginx/: Contains environment files for the proxy service.

  • /usr/share/keyrings/: Stores the Odoo repository GPG key.

Application installation process

The application is installed using a combination of native package management and dependency setup:

  1. Repository Setup: The official Odoo nightly repository is added to the system sources, and the corresponding GPG key is imported into /usr/share/keyrings/odoo-archive-keyring.gpg.

  2. Package Installation: The odoo package is installed via the system's package manager (apt).

  3. Python Dependencies:

  4. python3-pip is ensured to be present.

  5. For certain OS versions, xlwt and num2words are installed via pip to support Excel exports and textual amount rendering.

  6. PDF Generation Setup: The system installs wkhtmltopdf along with several required libraries (libqt5core5a, libqt5gui5, libqt5network5, libqt5printsupport5, libqt5svg5, libqt5webkit5, libqt5widgets5, and xvfb) to enable document printing and PDF generation.

Access Rights and Security

  • Firewall: The system is configured to listen on port 443 for secure traffic.

  • SSL/TLS: SSL certificates are managed via a Dockerized Certbot container, ensuring encrypted communication.

  • Proxy Configuration: An Nginx reverse proxy is configured to forward requests from the external domain to the local Odoo service running on 127.0.0.1:8069.

Databases

The application relies on an internal database connection (typically PostgreSQL, managed as part of the Odoo ecosystem) which communicates with the application via port 8069.

Docker Containers and Their Deployment

The deployment utilizes a containerized Nginx proxy to handle SSL termination and web traffic.

Container Name Image Ports Volumes Environment Variables Restart Policy
nginx jonasal/nginx-certbot:latest Host Network - nginx_secrets:/etc/letsencrypt
- /data/nginx/user_conf.d:/etc/nginx/user_conf.d
[email protected] (via .env) unless-stopped

Application Update Instructions

To update the main application, use the system package manager:

sudo apt update
sudo apt upgrade odoo

Location of configuration files and data

  • Nginx Configuration: /data/nginx/user_conf.d/odoo{Server_ID}.hostkey.in.conf

  • Docker Compose (Proxy): /root/nginx/compose.yml

  • Odoo Repository List: /etc/apt/sources.list.d/odoo.list

Available ports for connection

  • 443: Secure HTTPS access via the Nginx proxy.

  • 8069: Internal application port (accessible locally).

Starting and Stopping the application

The main Odoo service is managed as a system service:

  • Start/Restart: sudo systemctl restart odoo

  • Stop: sudo systemctl stop odoo

The Nginx proxy container can be managed via Docker:

  • Restart Proxy: docker exec nginx-nginx-1 nginx -s reload
question_mark
Is there anything I can help you with?
question_mark
AI Assistant ×