Skip to Content
Portfolio Matthias
  • Home
  • Contact me
  • Volg ons
  • Nederlands English (UK) Język polski
  • Sign in
Portfolio Matthias
      • Home
      • Contact me
    • Volg ons
    • Nederlands English (UK) Język polski
    • Sign in
    Dutch version | Polish version

    Project Description

    The deploy_odoo_mvs139.Jenkinsfile is a sophisticated Jenkins Pipeline designed for the automated deployment, management, and upgrading of Odoo stacks using Docker and Ansible. It provides a highly configurable workflow that handles environment initialization, custom addon synchronization, database backups, major version upgrades, and data restoration from live environments to test environments.

    Key features include:

    • Dynamic Parameters: Uses Active Choices to fetch real-time data from Gitea and Nexus.
    • Hybrid Deployment: Supports both simple addon synchronization and full container rebuilds.
    • Automated Upgrades: Handles Odoo major version upgrades including database migrations.
    • Environment Isolation: Clearly distinguishes between 'test' and 'prod' environments with specific safety checks.
    • Notifications: Sends deployment status updates to kChat.

    User Manual

    Pipeline Parameters

    Parameter Description
    ReconfigureParameters Used to reseed job parameters. Tick this if you want to update the UI configuration without running a full deployment.
    Full_DNS_record The target host for deployment (e.g., flow-test.dutchworld.nl).
    Rebuild_containers If checked, the Odoo containers will be rebuilt using the latest enterprise apps. If unchecked, only custom addons are synced.
    customBranch Dynamically fetched branch list from the customizations repository in Gitea.
    odooDeployVersion Dynamically fetched list of container tags (releases) from Nexus for the target Odoo version.
    restoreFromLive (Test environment only) If checked, restores the database and filestore from the live server.
    newTestDbName Optional suffix for the test database name.
    ansibleDebug Runs Ansible playbooks with high verbosity (-vvv) for troubleshooting.

    Deployment Workflow

    1. Initialization: The pipeline reads host_vars from the ansible repository to configure environment variables.
    2. Syncing Addons: If Rebuild_containers is false, the pipeline clones the custom addons repository and syncs them to the target host.
    3. Pre-Upgrade Actions:
      • On Test: Automatically restores data from Live if requested.
      • On Prod: Takes a full backup (DB + Filestore) before proceeding.
    4. Stack Deployment: Deploys the Odoo container stack using the specified version tag.
    5. Major Upgrade: If upgrade_status is true in host_vars, it triggers the Odoo database upgrade process.
    6. Post-Deployment: Finalizes the upgrade status in Gitea and sends notifications.

    English version | Polish version

    Handleiding

    Pipeline Parameters

    Parameter Omschrijving
    ReconfigureParameters Wordt gebruikt om jobparameters opnieuw in te stellen. Vink dit aan als je de UI-configuratie wilt bijwerken zonder een volledige deployment uit te voeren.
    Full_DNS_record De doelhost voor deployment (bijv. flow-test.dutchworld.nl).
    Rebuild_containers Als aangevinkt, worden de Odoo-containers opnieuw opgebouwd met de nieuwste enterprise apps. Als niet aangevinkt, worden alleen custom addons gesynchroniseerd.
    customBranch Dynamisch opgehaalde branchlijst uit het customizations repository in Gitea.
    odooDeployVersion Dynamisch opgehaalde lijst van container tags (releases) uit Nexus voor de doel-Odoo-versie.
    restoreFromLive (Alleen testomgeving) Als aangevinkt, wordt de database en filestore hersteld van de live server.
    newTestDbName Optionele suffix voor de testdatabasenaam.
    ansibleDebug Voert Ansible playbooks uit met hoge verbosity (-vvv) voor troubleshooting.

    Deployment Workflow

    1. Initialisatie: De pipeline leest host_vars uit het ansible repository om omgevingsvariabelen te configureren.
    2. Synchronisatie Addons: Als Rebuild_containers false is, kloont de pipeline het custom addons repository en synchroniseert deze naar de doelhost.
    3. Pre-Upgrade Acties:
      • Op Test: Herstelt automatisch data van Live als gevraagd.
      • Op Prod: Maakt een volledige backup (DB + Filestore) voor de upgrade.
    4. Stack Deployment: Deployt de Odoo container stack met het opgegeven versie tag.
    5. Major Upgrade: Als upgrade_status true is in host_vars, wordt het Odoo database upgrade proces gestart.
    6. Post-Deployment: Finaliseert de upgrade status in Gitea en verstuurt notificaties.

    English version | Dutch version

    Opis projektu

    deploy_odoo_mvs139.Jenkinsfile to zaawansowany Pipeline Jenkins zaprojektowany do automatycznego wdrażania, zarządzania i aktualizacji stosów Odoo za pomocą Docker i Ansible. Zapewnia wysoko konfigurowalny przepływ pracy, który obsługuje inicjalizację środowiska, synchronizację niestandardowych dodatków, kopie zapasowe baz danych, aktualizacje głównych wersji oraz przywracanie danych ze środowisk produkcyjnych do testowych.

    Kluczowe funkcje obejmują:

    • Dynamiczne parametry: Wykorzystuje Active Choices do pobierania danych w czasie rzeczywistym z Gitea i Nexus.
    • Hybrydowe wdrażanie: Obsługuje zarówno prostą synchronizację dodatków, jak i pełne przebudowy kontenerów.
    • Zautomatyzowane aktualizacje: Obsługuje główne aktualizacje wersji Odoo, w tym migracje baz danych.
    • Izolacja środowiska: Wyraźnie rozróżnia środowiska „test” i „prod” z określonymi kontrolami bezpieczeństwa.
    • Powiadomienia: Wysyła aktualizacje statusu wdrożenia do kChat.

    Instrukcja użytkownika

    Parametry Pipeline

    Parametr Opis
    ReconfigureParameters Używany do ponownego zainicjowania parametrów zadania. Zaznacz, jeśli chcesz zaktualizować konfigurację UI bez pełnego wdrożenia.
    Full_DNS_record Docelowy host do wdrożenia (np. flow-test.dutchworld.nl).
    Rebuild_containers Jeśli zaznaczone, kontenery Odoo zostaną przebudowane z użyciem najnowszych aplikacji enterprise. Jeśli nie, synchronizowane są tylko niestandardowe dodatki.
    customBranch Dynamically pobierana lista gałęzi z repozytorium personalizacji w Gitea.
    odooDeployVersion Dynamically pobierana lista tagów kontenerów (wydań) z Nexus dla docelowej wersji Odoo.
    restoreFromLive (Tylko środowisko testowe) Jeśli zaznaczone, przywraca bazę danych i filestore z serwera produkcyjnego.
    newTestDbName Opcjonalny sufiks nazwy bazy testowej.
    ansibleDebug Uruchamia playbooki Ansible z wysoką szczegółowością (-vvv) w celu rozwiązywania problemów.

    Proces wdrażania

    1. Inicjalizacja: Pipeline odczytuje host_vars z repozytorium ansible, aby skonfigurować zmienne środowiskowe.
    2. Synchronizacja dodatków: Jeśli Rebuild_containers jest ustawione na false, pipeline klonuje repozytorium niestandardowych dodatków i synchronizuje je na docelowym hoście.
    3. Przedaktualizacyjne działania:
      • W środowisku testowym: Automatycznie przywraca dane z produkcji, jeśli jest to wymagane.
      • W środowisku produkcyjnym: Tworzy pełną kopię zapasową (baza danych + filestore) przed kontynuacją.
    4. Wdrażanie stosu: Wdraża stos kontenerów Odoo z użyciem określonego tagu wersji.
    5. Główna aktualizacja: Jeśli upgrade_status jest ustawiony na true w host_vars, uruchamia proces aktualizacji bazy danych Odoo.
    6. Po wdrożeniu: Finalizuje status aktualizacji w Gitea i wysyła powiadomienia.


    Contact us

    Matthias de Vries
    Modrzewiowa 45
    55-200 Stanowice
    Poland

    • +48 798 999 562
    • matthiasek@gmail.com
    Copyright © Company name
    Nederlands | English (UK) | Język polski
    Aangeboden door Odoo - Create a free website