From 84fc1b22d06dbcd38285884a0f7a895a60ad1120 Mon Sep 17 00:00:00 2001 From: Philippe Caseiro Date: Wed, 24 Mar 2021 11:41:40 +0100 Subject: [PATCH] Update eole playbook for multi-version support --- .packer/provisioning/playbooks/eole/eole.yml | 16 +++++++++++++--- .packer/recipes/eole/2.7.2/eolebase.json | 14 ++++++++++++-- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/.packer/provisioning/playbooks/eole/eole.yml b/.packer/provisioning/playbooks/eole/eole.yml index 2b0dfc6..e1376b2 100644 --- a/.packer/provisioning/playbooks/eole/eole.yml +++ b/.packer/provisioning/playbooks/eole/eole.yml @@ -43,17 +43,17 @@ - name: Adding EOLE main repository apt_repository: - repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-2.7.2 main cloud + repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-{{ EOLE_VERSION }} main cloud state: present - name: Adding EOLE security repository apt_repository: - repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-2.7.2-security main cloud + repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-{{ EOLE_VERSION }}-security main cloud state: present - name: Adding EOLE updates repository apt_repository: - repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-2.7.2-updates main cloud + repo: deb [arch=amd64] http://eole.ac-dijon.fr/eole eole-{{ EOLE_VERSION }}-updates main cloud state: present - name: Update cache @@ -65,6 +65,16 @@ http_proxy: "{{ http_proxy }}" https_proxy: "{{ https_proxy }}" + - name: Install chromium browser on 2.7.2 + apt: + name: chromium-browser + environment: + HTTP_PROXY: "{{ http_proxy }}" + HTTPS_PROXY: "{{ https_proxy }}" + http_proxy: "{{ http_proxy }}" + https_proxy: "{{ https_proxy }}" + when: EOLE_VERSION == "2.7.2" + - name: Install eole-server and eole-exim-pkg apt: name: eole-server,eole-exim-pkg diff --git a/.packer/recipes/eole/2.7.2/eolebase.json b/.packer/recipes/eole/2.7.2/eolebase.json index 9775ad4..581c971 100644 --- a/.packer/recipes/eole/2.7.2/eolebase.json +++ b/.packer/recipes/eole/2.7.2/eolebase.json @@ -64,12 +64,22 @@ { "type": "ansible", "playbook_file": "{{user `eole_playbooks`}}/eole.yml", - "extra_arguments": [ "-vvvv", "--extra-vars", "VM_NAME={{ user `vm_name` }} HTTP_PROXY={{ user `HTTP_PROXY` }} HTTPS_PROXY={{ user `HTTPS_PROXY` }} http_proxy={{ user `http_proxy` }} https_proxy={{ user `https_proxy` }}"] + "extra_arguments": [ + "--extra-vars", + "VM_NAME={{ user `vm_name` }} EOLE_VERSION={{ user `eole_version` }}", + "--extra-vars", + "HTTP_PROXY={{ user `HTTP_PROXY` }} HTTPS_PROXY={{ user `HTTPS_PROXY` }} http_proxy={{ user `http_proxy` }} https_proxy={{ user `https_proxy` }}" + ] }, { "type":"ansible", "playbook_file":"{{ user `eole_playbooks` }}/provision.yml", - "extra_arguments": [ "--extra-vars", "VM_NAME={{ user `vm_name` }} HTTP_PROXY={{ user `HTTP_PROXY` }} HTTPS_PROXY={{ user `HTTPS_PROXY` }} http_proxy={{ user `http_proxy` }} https_proxy={{ user `https_proxy` }}"] + "extra_arguments": [ + "--extra-vars", + "VM_NAME={{ user `vm_name` }} EOLE_VERSION={{ user `eole_version` }}", + "--extra-vars", + "HTTP_PROXY={{ user `HTTP_PROXY` }} HTTPS_PROXY={{ user `HTTPS_PROXY` }} http_proxy={{ user `http_proxy` }} https_proxy={{ user `https_proxy` }}" + ] } ], "post-processors": [