Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to install x86 architecture for java using Ansible

I'm doing something like: dpkg --add-architecture i386 using command module in Ansible. But I want to use Ansible core module to achieve it.

apt module has a parameter "dpkg_options". But I haven't had any success installing this package.

Anyone have any ideas?

like image 556
ankit tyagi Avatar asked Apr 24 '15 08:04

ankit tyagi


1 Answers

This should work for you.

# 32-bit dependencies for Android binaries
- lineinfile: dest=/var/lib/dpkg/arch line="amd64" create=yes
- lineinfile: dest=/var/lib/dpkg/arch line="i386" create=yes
  register: add_i386
- apt: name={{item}} update_cache={{add_i386.changed}}
  with_items: ['libc6:i386', 'libstdc++6:i386', 'zlib1g:i386']
like image 160
Martin Nowak Avatar answered Nov 06 '22 10:11

Martin Nowak