From d6d1b91a79b3b74a5595a2b943041659ff5928bd Mon Sep 17 00:00:00 2001 From: Hendy Irawan Date: Sat, 3 Oct 2020 14:33:12 +0700 Subject: [PATCH 1/2] fix(playbooks): Support wkhtmltox arm64 architecture For Ubuntu 20.04 LTS and later --- bench/playbooks/roles/wkhtmltopdf/tasks/main.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml b/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml index aea2f55f..a2c6086d 100644 --- a/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml +++ b/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml @@ -20,11 +20,17 @@ force: yes when: ansible_os_family == 'Debian' -- name: download wkthmltox Ubuntu 20 +- name: download wkthmltox Ubuntu 20 amd64 get_url: url: https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.5/wkhtmltox_0.12.5-1.focal_amd64.deb dest: /tmp/wkhtmltox.deb - when: ansible_distribution == 'Ubuntu' and ansible_distribution_major_version == '20' + when: ansible_distribution == 'Ubuntu' and ansible_distribution_major_version == '20' and ansible_architecture == 'x86_64' +- name: download wkthmltox Ubuntu 20 arm64 + get_url: + # wkhtmltox supports arm64 starting from 0.12.6 + url: https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.focal_arm64.deb + dest: /tmp/wkhtmltox.deb + when: ansible_distribution == 'Ubuntu' and ansible_distribution_major_version == '20' and ansible_architecture == 'aarch64' - name: download wkthmltox Ubuntu 18 get_url: From 6ef6e37b80fd08ff45d6ae0171646b07c38b5641 Mon Sep 17 00:00:00 2001 From: Hendy Irawan Date: Fri, 30 Oct 2020 18:00:26 +0700 Subject: [PATCH 2/2] style: Apply suggestions from code review Co-authored-by: gavin --- bench/playbooks/roles/wkhtmltopdf/tasks/main.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml b/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml index a2c6086d..2a6a89ea 100644 --- a/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml +++ b/bench/playbooks/roles/wkhtmltopdf/tasks/main.yml @@ -20,11 +20,12 @@ force: yes when: ansible_os_family == 'Debian' -- name: download wkthmltox Ubuntu 20 amd64 +- name: download wkthmltox Ubuntu 20 get_url: url: https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.5/wkhtmltox_0.12.5-1.focal_amd64.deb dest: /tmp/wkhtmltox.deb - when: ansible_distribution == 'Ubuntu' and ansible_distribution_major_version == '20' and ansible_architecture == 'x86_64' + when: ansible_distribution == 'Ubuntu' and ansible_distribution_major_version == '20' and ansible_architecture != 'aarch64' + - name: download wkthmltox Ubuntu 20 arm64 get_url: # wkhtmltox supports arm64 starting from 0.12.6