From 88fca10b36ff2b90516c000f1b83cf7386c5a44d Mon Sep 17 00:00:00 2001 From: Romina Brown Date: Fri, 8 May 2026 19:27:23 -0300 Subject: [PATCH 1/4] Zimbra upgrade --- defaults/main.yml | 2 ++ tasks/install/zimbra.yml | 4 ++-- tasks/main.yml | 10 +++++----- templates/installZimbraUpgrade-keystrokes | 5 +++++ 4 files changed, 14 insertions(+), 7 deletions(-) create mode 100644 templates/installZimbraUpgrade-keystrokes diff --git a/defaults/main.yml b/defaults/main.yml index f819fa1..8e72ffb 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -45,6 +45,8 @@ timezone: UTC ################################################################################ zimbra_version: 8.8.15 +zimbra_upgrade: false + zm_repo: 8.8.15: url: https://files.zimbra.com/downloads/8.8.15_GA/ diff --git a/tasks/install/zimbra.yml b/tasks/install/zimbra.yml index 5f07580..4aa1a8c 100644 --- a/tasks/install/zimbra.yml +++ b/tasks/install/zimbra.yml @@ -29,7 +29,7 @@ - name: Uploading keystroke file template: - src: 'installZimbra-keystrokes' + src: "{{ 'installZimbra-keystrokes' if not zimbra_upgrade else 'installZimbraUpgrade-keystrokes' }}" dest: /tmp/zcs/installZimbra-keystrokes owner: root group: root @@ -49,6 +49,6 @@ chdir: '/usr/local/src/{{ zm_pkg }}/' - name: Configuring Zimbra OSE's services for use - command: ./zmsetup.pl -c /tmp/zcs/installZimbraScript + command: ./zmsetup.pl {{ '-c /tmp/zcs/installZimbraScript' if not zimbra_upgrade }} args: chdir: /opt/zimbra/libexec/ diff --git a/tasks/main.yml b/tasks/main.yml index f577fe9..7a417bc 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -11,9 +11,9 @@ # Installation process ################################################################################ - import_tasks: 'install/dependencies.yml' - when: getent_passwd.rc == 2 + when: getent_passwd.rc == 2 or zimbra_upgrade - import_tasks: 'install/zimbra.yml' - when: getent_passwd.rc == 2 + when: getent_passwd.rc == 2 or zimbra_upgrade - import_tasks: 'install/policyd.yml' when: zimbra_policyd == 'y' @@ -21,11 +21,11 @@ # Configuration process ################################################################################ - import_tasks: 'configure/proxy.yml' - when: zimbra_proxy == 'y' + when: zimbra_proxy == 'y' and not zimbra_upgrade - import_tasks: 'configure/mailbox.yml' - when: zimbra_store == 'y' + when: zimbra_store == 'y' and not zimbra_upgrade - import_tasks: 'configure/mta.yml' - when: zimbra_mta == 'y' + when: zimbra_mta == 'y' and not zimbra_upgrade - import_tasks: 'configure/disable_existing_dns_stub_listener.yml' when: zimbra_dnscache == 'y' and disable_existing_dns_stub_listener == 'y' diff --git a/templates/installZimbraUpgrade-keystrokes b/templates/installZimbraUpgrade-keystrokes new file mode 100644 index 0000000..3524cf2 --- /dev/null +++ b/templates/installZimbraUpgrade-keystrokes @@ -0,0 +1,5 @@ +y +n +y +y +y \ No newline at end of file From 24d8345ff3bb5cdb636c7a123714788fa1c460ad Mon Sep 17 00:00:00 2001 From: Romina Brown Date: Mon, 11 May 2026 14:07:17 -0300 Subject: [PATCH 2/4] Se agrega config file para upgrade --- tasks/install/zimbra.yml | 4 ++-- templates/installZimbraScriptUpgrade.j2 | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 templates/installZimbraScriptUpgrade.j2 diff --git a/tasks/install/zimbra.yml b/tasks/install/zimbra.yml index 4aa1a8c..6658fc8 100644 --- a/tasks/install/zimbra.yml +++ b/tasks/install/zimbra.yml @@ -37,7 +37,7 @@ - name: Uploading installer configuration file template: - src: 'installZimbraScript.j2' + src: "{{ 'installZimbraScript.j2' if not zimbra_upgrade else 'installZimbraScriptUpgrade.j2' }}" dest: /tmp/zcs/installZimbraScript owner: root group: root @@ -49,6 +49,6 @@ chdir: '/usr/local/src/{{ zm_pkg }}/' - name: Configuring Zimbra OSE's services for use - command: ./zmsetup.pl {{ '-c /tmp/zcs/installZimbraScript' if not zimbra_upgrade }} + command: ./zmsetup.pl -c /tmp/zcs/installZimbraScript args: chdir: /opt/zimbra/libexec/ diff --git a/templates/installZimbraScriptUpgrade.j2 b/templates/installZimbraScriptUpgrade.j2 new file mode 100644 index 0000000..8d584ce --- /dev/null +++ b/templates/installZimbraScriptUpgrade.j2 @@ -0,0 +1 @@ +zimbraNotifyInstall=no \ No newline at end of file From 76229e62b67b18fa99224bd139fb49d5c5316f37 Mon Sep 17 00:00:00 2001 From: Romina Brown Date: Tue, 12 May 2026 10:22:27 -0300 Subject: [PATCH 3/4] Reorganizing defaults --- defaults/main.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/defaults/main.yml b/defaults/main.yml index 8e72ffb..670ab97 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -39,14 +39,13 @@ zmnetwork: "192.168.200.0/8" timezone: UTC #hosts_lines: # - "198.162.1.3 {{ hostname }}.{{ domain }} {{ hostname }}" +disable_existing_dns_stub_listener: n # -# Zimbra repository +# Zimbra installers ################################################################################ zimbra_version: 8.8.15 -zimbra_upgrade: false - zm_repo: 8.8.15: url: https://files.zimbra.com/downloads/8.8.15_GA/ @@ -64,4 +63,5 @@ zm_repo: 6: zcs-8.8.15_GA_3869.RHEL6_64.20190918004220 7: zcs-8.8.15_GA_3869.RHEL7_64.20190918004220 8: zcs-8.8.15_GA_3953.RHEL8_64.20200629025823 -disable_existing_dns_stub_listener: n + +zimbra_upgrade: false \ No newline at end of file From a6ec0370632b67631d533859daafbdd6988d0eea Mon Sep 17 00:00:00 2001 From: Romina Brown Date: Tue, 2 Jun 2026 19:27:32 -0300 Subject: [PATCH 4/4] Se agrega variable zimbra_upgrade a readme --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index ed3cd9c..ac04dd7 100644 --- a/README.md +++ b/README.md @@ -73,6 +73,8 @@ zm_repo: ``` * **disable_existing_dns_stub_listener:** Inform "y" to disable the systemd-resolved DNS stub listener and free up port 53. Default: **n** +* **zimbra_upgrade:** Inform "y" to upgrade an existing Zimbra installation. Zimbra will be upgraded to **zimbra_version** version. Default: **n** + Service Variables - Inform "y" or "n" --------------