diff --git a/.gitignore b/.gitignore index 2bbde31..3e6cd24 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,13 @@ .DS_Store +.env +addons/ +config/ +datadir/ +log/ +scripts/ +postgresql/ +filestore/ +modulos.txt .vscode/ versions/16.0/.vscode/* versions/17.0/.vscode/* \ No newline at end of file diff --git a/backup_restore.sh b/backup_restore.sh new file mode 100644 index 0000000..baa5fec --- /dev/null +++ b/backup_restore.sh @@ -0,0 +1,102 @@ +#!/bin/bash + +# ======================== +# CARGAR VARIABLES DESDE .env +# ======================== +if [ -f .env ]; then + export $(grep -v '^#' .env | xargs) +else + echo "❌ Archivo .env no encontrado." + exit 1 +fi + +PROD_URL="$PROD_URL" +PROD_MASTER_KEY="$PROD_MASTER_KEY" +PG_DB="$PG_DB" +ODOO_PORT="${ODOO_PORT:-8069}" # Por defecto 8069 si no está definido + +BACKUP_FILE="odoo_backup.zip" +LOCAL_URL="http://localhost:$ODOO_PORT" + +# ======================== +# FUNCIÓN PARA VERIFICAR CONEXIÓN A ODOO +# ======================== +function verificar_conexion() { + URL=$1 + echo "🔍 Verificando conexión a $URL ..." + if curl -k -L -s --head --request GET "$URL/web/database/manager" | grep "200 OK" > /dev/null; then + echo "✅ Conexión exitosa a $URL" + else + echo "❌ No se pudo conectar a $URL" + exit 1 + fi +} + +# ======================== +# FUNCIÓN DE BACKUP +# ======================== +function backup_odoo() { + echo "🔵 Iniciando backup desde $PROD_URL de la base '$PG_DB'..." + verificar_conexion "$PROD_URL" + curl -k -L -X POST "https://$PROD_URL/web/database/backup" \ + -d "master_pwd=$PROD_MASTER_KEY" \ + -d "name=$PG_DB" \ + -d "backup_format=zip" \ + --output "$BACKUP_FILE" + + if [ $? -eq 0 ]; then + echo "✅ Backup completado: $BACKUP_FILE" + else + echo "❌ Error durante el backup." + exit 1 + fi +} + +# ======================== +# FUNCIÓN PARA ELIMINAR BASE DE DATOS LOCAL +# ======================== +function drop_local_db() { + echo "🗑️ Eliminando base '$PG_DB' en entorno local ($LOCAL_URL)..." + verificar_conexion "$LOCAL_URL" + curl -k -L -X POST "$LOCAL_URL/web/database/drop" \ + -d "master_pwd=$PROD_MASTER_KEY" \ + -d "name=$PG_DB" \ + -d "drop=true" +} + +# ======================== +# FUNCIÓN DE RESTORE EN LOCAL +# ======================== +function restore_local() { + echo "🟡 Restaurando backup en entorno local ($LOCAL_URL) con nombre '$PG_DB'..." + verificar_conexion "$LOCAL_URL" + curl -k -L -X POST "$LOCAL_URL/web/database/restore" \ + -F "master_pwd=$PROD_MASTER_KEY" \ + -F "name=$PG_DB" \ + -F "backup_file=@$BACKUP_FILE" \ + -F "copy=true" + + if [ $? -eq 0 ]; then + echo "✅ Restauración completada como '$PG_DB' en local" + else + echo "❌ Error durante la restauración." + exit 1 + fi +} + +# ======================== +# FUNCIÓN PARA LIMPIAR ARCHIVOS TEMPORALES +# ======================== +function limpiar_backup() { + echo "🧹 Eliminando archivo temporal $BACKUP_FILE..." + rm -f "$BACKUP_FILE" + echo "✅ Limpieza completada." +} + +# ======================== +# EJECUCIÓN COMPLETA +# ======================== +limpiar_backup +backup_odoo +drop_local_db +restore_local \ No newline at end of file diff --git a/clean_db.sh b/clean_db.sh new file mode 100644 index 0000000..380e978 --- /dev/null +++ b/clean_db.sh @@ -0,0 +1,49 @@ +#!/bin/bash + +# ======================== +# CARGAR VARIABLES DESDE .env +# ======================== +if [ -f .env ]; then + export $(grep -v '^#' .env | xargs) +else + echo "❌ Archivo .env no encontrado." + exit 1 +fi + +PG_DB="$PG_DB" +PG_USER="$PG_USER" +PG_CONTAINER_NAME="$PG_CONTAINER_NAME" +ODOO_CONTAINER_NAME="$ODOO_CONTAINER_NAME" +PG_PASSWORD="$PG_PASSWORD" + + +# ======================== +# COMANDOS SQL QUE VAMOS A EJECUTAR +# ======================== +SQL=$(cat </dev/null; then + echo "✅ Repositorio '$repo_name' clonado en la branch '$branch'." + else + echo "⚠️ No se encontró la branch '$branch' en '$repo_url'. Clonando la branch por defecto..." + if git clone "$repo_url_with_auth" "$target_dir"; then + echo "✅ Repositorio '$repo_name' clonado en la branch por defecto." + else + echo "❌ Error al clonar '$repo_url'." + fi + fi + fi + else + echo "⚠️ No se encontró una URL válida en la línea: $line" + fi + +done < "$MODULES_FILE" + +echo "🔄 Proceso de clonación finalizado." diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..4e8d772 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,49 @@ +networks: + odoo: + +services: + postgres: + #container_name: ${PG_CONTAINER_NAME} + image: ${PG_IMAGE}:${PG_VERSION} + user: root + environment: + - POSTGRES_DB=${PG_DB} + - POSTGRES_USER=${PG_USER} + - POSTGRES_PASSWORD=${PG_PASSWORD} + - PGDATA=/var/lib/postgresql/data/pgdata + ports: + - ${PG_PORT}:5432 + volumes: + - ${PG_PATH}:/var/lib/postgresql/data + networks: + - odoo + + odoo: + #container_name: ${ODOO_CONTAINER_NAME} + #image: ${ODOO_IMAGE}:${ODOO_VERSION} + build: versions/16.0/. + restart: unless-stopped + entrypoint: ["/scripts/entrypoint.sh"] + user: root + depends_on: + - postgres + ports: + - ${ODOO_PORT}:8069 + volumes: + - ./entrypoint.sh:/scripts/entrypoint.sh # Monta entrypoint.sh en el contenedor + - ./modulos.txt:/scripts/modulos.txt # Monta modulos.txt en el contenedor + - ${CONF_PATH}:/opt/etc/odoo + - ${DATA_PATH}:/opt/odoo/data + - ${LOG_PATH}:/var/log/odoo + - ${CUSTOM_ADDONS}:/mnt/extra-addons + - ${SCRIPT_PATH}:/scripts + - ${FILE_PATH}:/var/lib/odoo + environment: + - HOST=postgres + - CUSTOM_ADDONS=${CUSTOM_ADDONS} + - MAIN_MODULE=${MAIN_MODULE} + - POSTGRES_DB=${PG_DB} + - POSTGRES_USER=${PG_USER} + - POSTGRES_PASSWORD=${PG_PASSWORD} + networks: + - odoo diff --git a/entrypoint.sh b/entrypoint.sh new file mode 100755 index 0000000..e0dcfd7 --- /dev/null +++ b/entrypoint.sh @@ -0,0 +1,96 @@ +#!/bin/bash +set -e + +# Validar variables de entorno +: "${HOST:?Variable HOST no definida}" +: "${POSTGRES_DB:?Variable POSTGRES_DB no definida}" +: "${POSTGRES_USER:?Variable POSTGRES_USER no definida}" +: "${POSTGRES_PASSWORD:?Variable POSTGRES_PASSWORD no definida}" +: "${MAIN_MODULE:?Variable MAIN_MODULE no definida}" + +# Rutas +ADDONS_DIR="/mnt/extra-addons" +ORIGINAL_CONFIG="/etc/odoo/odoo.conf" +MODIFIED_CONFIG="/var/lib/odoo/odoo.conf" + +echo "Esperando a que PostgreSQL esté disponible..." +for i in {1..30}; do + if pg_isready -h "$HOST" -p 5432; then + echo "PostgreSQL está listo." + break + fi + echo "Esperando... intento $i/30" + sleep 1 +done + +if ! pg_isready -h "$HOST" -p 5432; then + echo "❌ No se pudo conectar a PostgreSQL. Abortando..." + exit 1 +fi + +# Obtener rutas actuales de addons +CUSTOM_ADDONS_PATHS=$(odoo --config="$ORIGINAL_CONFIG" --print-addon-paths 2>/dev/null | tr ':' '\n') + +echo "📂 Rutas de módulos en Odoo actualmente:" +echo "$CUSTOM_ADDONS_PATHS" + +# Leer todas las carpetas dentro de /mnt/extra-addons +EXTRA_PATHS=() +for dir in "$ADDONS_DIR"/*/; do + if [ -d "$dir" ]; then + echo "Encontrado módulo/carpeta: $dir" + if ! echo "$CUSTOM_ADDONS_PATHS" | grep -q "$dir"; then + echo "➕ Agregando $dir a addons_path." + EXTRA_PATHS+=("$dir") + else + echo "✅ $dir ya está en addons_path." + fi + fi +done + +# Generar nuevo archivo de configuración si hay nuevas rutas +if [ ${#EXTRA_PATHS[@]} -gt 0 ]; then + echo "🛠️ Generando archivo de configuración modificado en $MODIFIED_CONFIG..." + + # Si el archivo de destino no existe, copiar el original + if [ ! -f "$MODIFIED_CONFIG" ]; then + cp "$ORIGINAL_CONFIG" "$MODIFIED_CONFIG" + echo "📄 Copia base creada desde el archivo original." + else + echo "📄 Usando archivo de configuración existente en el destino." + fi + + # Leer línea actual de addons_path + ADDONS_PATH=$(grep -E '^addons_path\s*=' "$MODIFIED_CONFIG" | cut -d'=' -f2 | tr -d ' ') + + # Concatenar las nuevas rutas + NEW_ADDONS_PATH="$ADDONS_PATH,$(IFS=,; echo "${EXTRA_PATHS[*]}")" + + # Reemplazar en el archivo copiado o existente + sed -i "s|^addons_path\s*=.*|addons_path = $NEW_ADDONS_PATH|" "$MODIFIED_CONFIG" + + echo "✅ addons_path actualizado con éxito." +else + echo "No se encontraron nuevas rutas para agregar al addons_path." + + # Si no hay cambios, usar el config original solo si no existe el modificado + if [ ! -f "$MODIFIED_CONFIG" ]; then + cp "$ORIGINAL_CONFIG" "$MODIFIED_CONFIG" + echo "📄 Copia base creada desde el archivo original (sin cambios en addons_path)." + else + echo "📄 Archivo de configuración ya existe. No se realizaron cambios." + fi +fi + + +# Verificar si el módulo principal está instalado +echo "🔍 Verificando si el módulo $MAIN_MODULE ya está instalado..." +INSTALLED_MODULES=$(PGPASSWORD="$POSTGRES_PASSWORD" psql -h "$HOST" -U "$POSTGRES_USER" -d "$POSTGRES_DB" -t -c "SELECT name FROM ir_module_module WHERE state = 'installed';" | tr -d ' ' | tr ',' '\n') + +if echo "$INSTALLED_MODULES" | grep -Fxq "$MAIN_MODULE"; then + echo "✅ El módulo $MAIN_MODULE ya está instalado. Iniciando Odoo normalmente..." + exec odoo --config="$MODIFIED_CONFIG" -d "$POSTGRES_DB" --db-filter="$POSTGRES_DB" --db_host="$HOST" --db_port=5432 --db_user="$POSTGRES_USER" --db_password="$POSTGRES_PASSWORD" +else + echo "🚀 El módulo $MAIN_MODULE no está instalado. Procediendo con la instalación..." + exec odoo --config="$MODIFIED_CONFIG" -i "$MAIN_MODULE" -d "$POSTGRES_DB" --db-filter="$POSTGRES_DB" --db_host="$HOST" --db_port=5432 --db_user="$POSTGRES_USER" --db_password="$POSTGRES_PASSWORD" --without-demo=True +fi diff --git a/env.example b/env.example new file mode 100644 index 0000000..9a79fd7 --- /dev/null +++ b/env.example @@ -0,0 +1,30 @@ +COMPOSE_PROJECT_NAME= + +ODOO_IMAGE= +ODOO_VERSION= +ODOO_CONTAINER_NAME= +ODOO_PORT= + +ODOO_SCRIPTS_CONTAINER_NAME= +MAIN_MODULE= + +PG_CONTAINER_NAME= +PG_IMAGE= +PG_VERSION= +PG_DB= +PG_USER= +PG_PASSWORD= +PG_PORT= +PG_PATH= + +CUSTOM_ADDONS= +CONF_PATH= +DATA_PATH= +LOG_PATH= +SCRIPT_PATH= +FILE_PATH= + + +#Usar solo en ambiente dev +PROD_URL= +PROD_MASTER_KEY= \ No newline at end of file diff --git a/versions/16.0/Dockerfile b/versions/16.0/Dockerfile index ed52211..5d7e5ae 100644 --- a/versions/16.0/Dockerfile +++ b/versions/16.0/Dockerfile @@ -4,7 +4,7 @@ LABEL maintainer="Odoo S.A. " SHELL ["/bin/bash", "-xo", "pipefail", "-c"] # Generate locale C.UTF-8 for postgres and general locale data -ENV LANG C.UTF-8 +ENV LANG=C.UTF-8 # Retrieve the target architecture to install the correct wkhtmltopdf package ARG TARGETARCH @@ -33,7 +33,6 @@ RUN apt-get update && \ python3-slugify \ python3-vobject \ python3-watchdog \ - python3-xlrd \ python3-xlwt \ xz-utils && \ if [ -z "${TARGETARCH}" ]; then \ @@ -68,9 +67,10 @@ RUN echo 'deb http://apt.postgresql.org/pub/repos/apt/ bullseye-pgdg main' > /et RUN npm install -g rtlcss # Install Odoo -ENV ODOO_VERSION 16.0 -ENV ODOO_RELEASE=latest -#ARG ODOO_SHA=3b24f0d4cd39879d60bee66331091e202fa2675b +ENV ODOO_VERSION=16.0 +ARG ODOO_RELEASE=20250204 +#ARG ODOO_SHA=1fb02a432e076dd71aca7a7611a07223919356b9 + RUN curl -o odoo.deb -sSL http://nightly.odoo.com/${ODOO_VERSION}/nightly/deb/odoo_${ODOO_VERSION}.${ODOO_RELEASE}_all.deb \ # && echo "${ODOO_SHA} odoo.deb" | sha1sum -c - \ && apt-get update \ @@ -91,7 +91,7 @@ VOLUME ["/var/lib/odoo", "/mnt/extra-addons"] EXPOSE 8069 8071 8072 # Set the default config file -ENV ODOO_RC /etc/odoo/odoo.conf +ENV ODOO_RC=/etc/odoo/odoo.conf COPY wait-for-psql.py /usr/local/bin/wait-for-psql.py @@ -106,16 +106,16 @@ CMD ["odoo"] ############################################################################### FROM base-image -LABEL maintainer="Gacho Code " +LABEL maintainer="Jorge Obiols " USER root -ENV ETC_DIR /opt/odoo/etc -ENV DATA_DIR /opt/odoo/data -ENV LOG_DIR /var/log/odoo -ENV BKP_DIR /var/odoo/backups -ENV ADDONS_DIR /opt/odoo/custom-addons -ENV ODOO_RC ${ETC_DIR}/odoo.conf +ENV ETC_DIR=/etc/odoo +ENV DATA_DIR=/opt/odoo/data +ENV LOG_DIR=/var/log/odoo +ENV BKP_DIR=/var/odoo/backups +ENV ADDONS_DIR=/opt/odoo/custom-addons +ENV ODOO_RC=${ETC_DIR}/odoo.conf RUN \ mkdir -p ${ETC_DIR} \ && mkdir -p ${DATA_DIR} \ @@ -133,25 +133,18 @@ RUN curl -fsSL https://bootstrap.pypa.io/get-pip.py -o get-pip.py \ RUN apt-get -qq update && apt-get install -yqq --no-install-recommends \ git python3-dev build-essential -RUN apt-get install -y --no-install-recommends \ - procps \ - net-tools \ - nmap \ - vim - COPY ./requirements /req RUN pip3 install -r /req/requirements.txt RUN pip3 install -r /req/odoo-argentina.txt +#RUN pip3 install -r /req/adhoc-aeroo_reports.txt RUN rm -r /req # crear cache para pyafipws lo necesita para actualizar desde padron y darle # permisos para que pueda escribir desde pyafipws porque ahi hay una base # sqlite que se usa cuando se refrescan actividades, impuestos y conceptos. RUN mkdir /usr/local/lib/python3.9/dist-packages/pyafipws/cache -RUN chmod -R o+w /usr/local/lib/python3.9/dist-packages/pyafipws +RUN chmod -R 777 /usr/local/lib/python3.9/dist-packages/pyafipws # bajar el cifrado del cliente para evitar el error DH_KEY_TOO_SMALL # parece que la afip tiene un cifrado debil. -RUN sed -i "s/CipherString = DEFAULT@SECLEVEL=2/CipherString = DEFAULT@SECLEVEL=1/" /etc/ssl/openssl.cnf - -USER odoo \ No newline at end of file +RUN sed -i "s/CipherString = DEFAULT@SECLEVEL=2/CipherString = DEFAULT@SECLEVEL=1/" /etc/ssl/openssl.cnf \ No newline at end of file diff --git a/versions/16.0/entrypoint.sh b/versions/16.0/entrypoint.sh index a9e9914..5f9509c 100755 --- a/versions/16.0/entrypoint.sh +++ b/versions/16.0/entrypoint.sh @@ -47,4 +47,4 @@ case "$1" in exec "$@" esac -exit 1 \ No newline at end of file +exit 1 diff --git a/versions/16.0/make.sh b/versions/16.0/make.sh index df9c729..a129c2d 100644 --- a/versions/16.0/make.sh +++ b/versions/16.0/make.sh @@ -1,9 +1,9 @@ #!/usr/bin/env bash -sd build --rm=true -t gauchocode/odoo-gc:16.0 ./ +sd build --rm=true -t jobiols/odoo-jeo:16.0 ./ result=$? if [ "$result" -eq 0 ]; then - sd push gauchocode/odoo-gc:16.0 + sd push jobiols/odoo-jeo:16.0 else echo "Falló la creación de la imagen" fi -exit $return_code +exit $result diff --git a/versions/16.0/odoo.conf b/versions/16.0/odoo.conf index 141f040..22e2093 100644 --- a/versions/16.0/odoo.conf +++ b/versions/16.0/odoo.conf @@ -1,405 +1,37 @@ [options] -; =================== -; | Common options) | -; =================== -; ------ -; -c / --config | specify alternate config file -; ------ -; config = - -; ------ -; -s / --save | save configuration to ~/.odoorc (or to ~/.openerp_serverrc if it exists) -; ------ -; save = - -; ------ -; -i / --init | install one or more modules (comma-separated list, use "all" for all modules), requires -d -; ------ -; init = - -; ------ -; -u / --update | update one or more modules (comma-separated list, use "all" for all modules). Requires -d. -; ------ -; update = - -; ------ -; --without-demo | disable loading demo data for modules to be installed (comma-separated, use "all" for all modules). Requires -d and -i. Default is %default -; ------ -; without_demo = - -; ------ -; -P / --import-partial | Use this for big data importation, if it crashes you will be able to continue at the current state. Provide a filename to store intermediate importation states. -; ------ -; import_partial = - -; ------ -; --pidfile | file where the server pid will be stored -; ------ -; pidfile = - -; ------ -; --addons-path | type = string | specify additional addons paths (separated by commas). -; ------ - -addons_path = /opt/odoo/data/addons,/mnt/extra-addons - -; ------ -; --upgrade-path | type = string | specify an additional upgrade path. -; ------ -; upgrade_path = - -; ------ -; --load | Comma-separated list of server-wide modules. -; ------ -; server_wide_modules = base,web - -; ------ -; -D / --data-dir | Directory where to store Odoo data -; ------ -data_dir = /opt/odoo/data - +addons_path = /mnt/extra-addons +data_dir = /var/lib/odoo ; admin_passwd = admin - -; ============================== -; | HTTP Service Configuration | -; ============================== -; ------ -; --http-interface | Listen interface address for HTTP services. Keep empty to listen on all interfaces (0.0.0.0) -; ------ -; http_interface = - -; ------ -; -p / --http-port | type = int | Listen port for the main HTTP service -; ------ -; http_port = 8090 -xmlrpc_port = 8069 - -; ------ -; --longpolling-port | type = int | Listen port for the longpolling HTTP service -; ------ -; Old setting (deprecated) -; longpolling_port = 8072 -; gevent_port = 8072 - -; ------ -; --no-http | Disable the HTTP and Longpolling services entirely -; ------ -; http_enable = True - -; ------ -; --proxy-mode | Activate reverse proxy WSGI wrappers (headers rewriting) Only enable this when running behind a trusted web proxy! -; ------ -proxy_mode = False - -; ------ -; --xmlrpc-interface | SUPPRESSHELP -; ------ -; http_interface = - -; ------ -; --xmlrpc-port | type = int | SUPPRESSHELP -; ------ -; http_port = - -; ------ -; --no-xmlrpc | SUPPRESSHELP -; ------ -; http_enable = - -; =============================== -; | Web interface Configuration | -; =============================== -; ------ -; --db-filter | Regular expressions for filtering available databases for Web UI. The expression can use %d (domain) and %h (host) placeholders. -; ------ -; dbfilter = monaco_tes - -; ========================= -; | Testing Configuration | -; ========================= -; ------ -; --test-file | Launch a python test file. -; ------ -; test_file = - -; ------ -; --test-enable | Enable unit tests. -; ------ -; test_enable = - -; ------ -; --test-tags | Comma-separated list of spec to filter which tests to execute. Enable unit tests if set. A filter spec has the format: [-][tag][/module][:class][.method] The '-' specifies if we want to include or exclude tests matching this spec. The tag will match tags added on a class with a @tagged decorator. By default tag value is 'standard' when not given on include mode. '*' will match all tags. Tag will also match module name (deprecated, use /module) The module, class, and method will respectively match the module name, test class name and test method name. examples: :TestClass.test_func,/test_module,external -; ------ -; test_tags = - -; ------ -; --screencasts | Screencasts will go in DIR/{db_name}/screencasts. -; ------ -; screencasts = - -; ------ -; --screenshots | Screenshots will go in DIR/{db_name}/screenshots. Defaults to /etc/odoo/odoo_tests. -; ------ -; screenshots = /etc/odoo/odoo_tests - -; ========================= -; | Logging Configuration | -; ========================= -; ------ -; --logfile | file where the server log will be stored -; ------ -; logfile = /etc/odoo/odoo-server.log -logfile = /var/log/odoo/odoo.log - -; ------ -; --syslog | Send the log to the syslog server -; ------ -; syslog = - -; ------ -; --log-handler | setup a handler at LEVEL for a given PREFIX. An empty PREFIX indicates the root logger. This option can be repeated. Example: "odoo.orm:DEBUG" or "werkzeug:CRITICAL" (default: ":INFO") -; ------ -; None = :INFO - -; ------ -; --log-request | shortcut for --log-handler=odoo.http.rpc.request:DEBUG -; ------ -; log_handler = - -; ------ -; --log-response | shortcut for --log-handler=odoo.http.rpc.response:DEBUG -; ------ -; log_handler = - -; ------ -; --log-web | shortcut for --log-handler=odoo.http:DEBUG -; ------ -; log_handler = - -; ------ -; --log-sql | shortcut for --log-handler=odoo.sql_db:DEBUG -; ------ -; log_handler = - -; ------ -; --log-db | Logging database -; ------ -; log_db = - -; ------ -; --log-db-level | Logging database level -; ------ -; log_db_level = warning - -; ------ -; --log-level | type = choice | choices = ['info', 'debug_rpc', 'warn', 'test', 'critical', 'runbot', 'debug_sql', 'error', 'debug', 'debug_rpc_answer', 'notset'] | specify the level of the logging. Accepted values: ['info', 'debug_rpc', 'warn', 'test', 'critical', 'runbot', 'debug_sql', 'error', 'debug', 'debug_rpc_answer', 'notset']. -; ------ -; log_level = info - -; ====================== -; | SMTP Configuration | -; ====================== -; ------ -; --email-from | specify the SMTP email address for sending email -; ------ -; email_from = - -; ------ -; --smtp | specify the SMTP server for sending email -; ------ -; smtp_server = localhost - -; ------ -; --smtp-port | type = int | specify the SMTP port -; ------ -; smtp_port = 25 - -; ------ -; --smtp-ssl | if passed, SMTP connections will be encrypted with SSL (STARTTLS) -; ------ -; smtp_ssl = - -; ------ -; --smtp-user | specify the SMTP username for sending email -; ------ -; smtp_user = - -; ------ -; --smtp-password | specify the SMTP password for sending email -; ------ -; smtp_password = - -; ============================ -; | Database related options | -; ============================ -; ------ -; -d / --database | specify the database name -; ------ -db_name = False - -; ------ -; -r / --db_user | specify the database user name -; ------ -db_user = odoo - -; ------ -; -w / --db_password | specify the database password -; ------ -db_password = odoo - -; ------ -; --pg_path | specify the pg executable path -; ------ -; pg_path = - -; ------ -; --db_host | specify the database host -; ------ -db_host = postgres - -; ------ -; --db_port | type = int | specify the database port -; ------ -db_port = 5432 - -; ------ -; --db_sslmode | type = choice | choices = ['disable', 'allow', 'prefer', 'require', 'verify-ca', 'verify-full'] | specify the database ssl connection mode (see PostgreSQL documentation) -; ------ -; db_sslmode = prefer - -; ------ -; --db_maxconn | type = int | specify the maximum number of physical connections to PostgreSQL -; ------ +; csv_internal_sep = , ; db_maxconn = 64 - -; ------ -; --db-template | specify a custom database template to create a new database -; ------ -; db_template = template0 - -; ======================== -; | Internationalisation | -; ======================== -; ------ -; --load-language | specifies the languages for the translations you want to be loaded -; ------ -; load_language = - -; ------ -; -l / --language | specify the language of the translation file. Use it with --i18n-export or --i18n-import -; ------ -; language = - -; ------ -; --i18n-export | export all sentences to be translated to a CSV file, a PO file or a TGZ archive and exit -; ------ -; translate_out = - -; ------ -; --i18n-import | import a CSV or a PO file with translations and exit. The '-l' option is required. -; ------ -; translate_in = - -; ------ -; --i18n-overwrite | overwrites existing translation terms on updating a module or importing a CSV or a PO file. -; ------ -; overwrite_existing_translations = - -; ------ -; --modules | specify modules to export. Use in combination with --i18n-export -; ------ -; translate_modules = - -; ============================ -; | Security-related options | -; ============================ -; ------ -; --no-database-list | Disable the ability to obtain or view the list of databases. Also disable access to the database manager and selector, so be sure to set a proper --database parameter first -; ------ -;list_db = True - -; ==================== -; | Advanced options | -; ==================== -; ------ -; --dev | type = string | Enable developer mode. Param: List of options separated by comma. Options : all, [pudb|wdb|ipdb|pdb], reload, qweb, werkzeug, xml -; ------ -dev_mode = reload - -; ------ -; --shell-interface | type = string | Specify a preferred REPL to use in shell mode. Supported REPLs are: [ipython|ptpython|bpython|python] -; ------ -; shell_interface = - -; ------ -; --stop-after-init | stop the server after its initialization -; ------ -; stop_after_init = - -; ------ -; --osv-memory-count-limit | type = int | Force a limit on the maximum number of records kept in the virtual osv_memory tables. The default is False, which means no count-based limit. -; ------ -; osv_memory_count_limit = - -; ------ -; --transient-age-limit | type = float | Time limit (decimal value in hours) records created with a TransientModel (mosly wizard) are kept in the database. Default to 1 hour. -; ------ -; transient_age_limit = 1.0 - -; ------ -; --osv-memory-age-limit | type = float | Deprecated alias to the transient-age-limit option -; ------ -; osv_memory_age_limit = - -; ------ -; --max-cron-threads | type = int | Maximum number of threads processing concurrently cron jobs (default 2). -; ------ -max_cron_threads = 2 - -; ------ -; --unaccent | Try to enable the unaccent extension when creating new databases. -; ------ -unaccent = True - -; ------ -; --geoip-db | Absolute path to the GeoIP database file. -; ------ -; geoip_database = /usr/share/GeoIP/GeoLite2-City.mmdb - -; =========================== -; | Multiprocessing options | -; =========================== -; ------ -; --workers | type = int | Specify the number of workers, 0 disable prefork mode. -; ------ -workers = 0 - -; ------ -; --limit-memory-soft | type = int | Maximum allowed virtual memory per worker (in bytes), when reached the worker be reset after the current request (default 2048MiB). -; ------ -; limit_memory_soft = 2147483648 - -; ------ -; --limit-memory-hard | type = int | Maximum allowed virtual memory per worker (in bytes), when reached, any memory allocation will fail (default 2560MiB). -; ------ +; db_name = False +; db_template = template1 +; dbfilter = .* +; debug_mode = False +; email_from = False ; limit_memory_hard = 2684354560 - -; ------ -; --limit-time-cpu | type = int | Maximum allowed CPU time per request (default 60). -; ------ -limit_time_cpu = 600 - -; ------ -; --limit-time-real | type = int | Maximum allowed Real time per request (default 120). -; ------ -limit_time_real = 1200 - -; ------ -; --limit-time-real-cron | type = int | Maximum allowed Real time per cron job. (default: --limit-time-real). Set to 0 for no limit. -; ------ -limit_time_real_cron = -1 - -; ------ -; --limit-request | type = int | Maximum number of request to be processed per worker (default 8192). -; ------ -; limit_request = 8192 \ No newline at end of file +; limit_memory_soft = 2147483648 +; limit_request = 8192 +; limit_time_cpu = 60 +; limit_time_real = 120 +; list_db = True +; log_db = False +; log_handler = [':INFO'] +; log_level = info +; logfile = None +; longpolling_port = 8072 +; max_cron_threads = 2 +; osv_memory_age_limit = 1.0 +; osv_memory_count_limit = False +; smtp_password = False +; smtp_port = 25 +; smtp_server = localhost +; smtp_ssl = False +; smtp_user = False +; workers = 0 +; xmlrpc = True +; xmlrpc_interface = +; xmlrpc_port = 8069 +; xmlrpcs = True +; xmlrpcs_interface = +; xmlrpcs_port = 8071 diff --git a/versions/16.0/requirements/adhoc-aeroo_reports.txt b/versions/16.0/requirements/adhoc-aeroo_reports.txt new file mode 100644 index 0000000..4ed5860 --- /dev/null +++ b/versions/16.0/requirements/adhoc-aeroo_reports.txt @@ -0,0 +1,6 @@ +# use this genshi version to fix error when, for eg, you send arguments like "date=True" check this https://genshi.edgewall.org/ticket/600 +git+https://github.com/edgewall/genshi@stable/0.7.x +# git+https://github.com/aeroo/aeroolib.git +# waiting for PR https://github.com/aeroo/aeroolib/pull/12 +git+https://github.com/adhoc-dev/aeroolib@master-fix-ods +git+https://github.com/aeroo/currency2text.git \ No newline at end of file diff --git a/versions/16.0/requirements/odoo-argentina.txt b/versions/16.0/requirements/odoo-argentina.txt index 80f8da5..ba85f84 100644 --- a/versions/16.0/requirements/odoo-argentina.txt +++ b/versions/16.0/requirements/odoo-argentina.txt @@ -1,4 +1,4 @@ httplib2==0.20.4 git+https://github.com/pysimplesoap/pysimplesoap@a330d9c4af1b007fe1436f979ff0b9f66613136e git+https://github.com/ingadhoc/pyafipws@py3k -git+https://github.com/OCA/openupgradelib/@master \ No newline at end of file +git+https://github.com/OCA/openupgradelib/@master diff --git a/versions/16.0/requirements/requirements.txt b/versions/16.0/requirements/requirements.txt index ca36071..c5d58a3 100644 --- a/versions/16.0/requirements/requirements.txt +++ b/versions/16.0/requirements/requirements.txt @@ -2,9 +2,6 @@ num2words==0.5.10 pandas==2.2.2 paramiko==3.1.0 astor -gevent -greenlet -websockets # LOPEZ hr_attendance_zktecho pyzk @@ -13,4 +10,10 @@ sqlparse # upgrade utils git+https://github.com/odoo/upgrade-util@master -markdown \ No newline at end of file +markdown + +meli @ git+https://github.com/mercadolibre/python-sdk.git@09406bd544b974b379fea4818bd1040c7f147a40 + +unrar +openpyxl +xlrd==2.0.1 \ No newline at end of file diff --git a/versions/16.0/wait-for-psql.py b/versions/16.0/wait-for-psql.py index a2c1136..6444b2f 100755 --- a/versions/16.0/wait-for-psql.py +++ b/versions/16.0/wait-for-psql.py @@ -38,7 +38,7 @@ # ALTER FUNCTION unaccent(text) IMMUTABLE; # """ - # print(sql) +# print(sql) # cr = conn.cursor() # cr.execute(sql) @@ -61,4 +61,4 @@ if error: print("Database connection failure: %s" % error, file=sys.stderr) - sys.exit(1) \ No newline at end of file + sys.exit(1)