Skip to content
Snippets Groups Projects
Commit 68d1c44b authored by Fabio Santaniello's avatar Fabio Santaniello
Browse files

adding ansys for ubuntu 20.04

parent e8f5500d
No related branches found
No related tags found
No related merge requests found
......@@ -2,8 +2,13 @@
# defaults file for ansible_ansys
s3_base_url: https://s3.epfl.ch/10282-70726cc2c34fcfe7d4325ef7ea151411
ansys_install_version: ansysR2021
ansys_install_version_ubuntu: ANSYS2022R2
ansys_versions:
ANSYS2022R2:
url1: ANSYS2022R2_LINX64_Disk1.iso
url2: ANSYS2022R2_LINX64_Disk2.iso
url3: ANSYS2022R2_LINX64_Disk3.iso
ansysR2021:
url: ansysR2021.zip
password: !vault |
......
......@@ -3,7 +3,7 @@
- include: ubuntu.yml tags=debian
when: ansible_distribution == "Ubuntu" and ansible_distribution_major_version == "18"
- include: ubuntu.yml tags=debian
- include: ubuntu2004.yml tags=debian
when: ansible_distribution == "Ubuntu" and ansible_distribution_major_version == "20"
- include: centos.yml tags=centos
......
---
# tasks file for ansible_ansys
#Not supported for the moment by Ansys
\ No newline at end of file
---
- name: check if ansys installed
become: yes
stat:
path: "{{ ansys_path }}"
register: installed_ansys
- name: install ansys requirements for all products
become: yes
apt:
state: latest
pkg:
- libasound2
- libatk-bridge2.0-0
- libatk1.0-0
- libatspi2.0-0
- libavahi-client3
- libavahi-common3
- libblkid1
- libbsd0
- libc6
- libcairo-gobject2
- libcairo2
- libcom-err2
- libcups2
- libdatrie1
- libdbus-1-3
- libdrm2
- libepoxy0
- libexpat1
- libffi7
- libfontconfig1
- libfreetype6
- libfribidi0
- libgbm1
- libgcc-s1
- libgcrypt20
- libgdk-pixbuf2.0-0
- libglib2.0-0
- libgmp10
- libgnutls30
- libgpg-error0
- libgraphite2-3
- libgssapi-krb5-2
- libgtk-3-0
- libharfbuzz0b
- libhogweed5
- libice6
- libidn2-0
- libk5crypto3
- libkeyutils1
- libkrb5-3
- libkrb5support0
- liblz4-1
- liblzma5
- libmount1
- libnettle7
- libnspr4
- libnss3
- libp11-kit0
- libpango-1.0-0
- libpangocairo-1.0-0
- libpangoft2-1.0-0
- libpcre2-8-0
- libpcre3
- libpixman-1-0
- libpng16-16
- libselinux1
- libsm6
- libsqlite3-0
- libsystemd0
- libtasn1-6
- libthai0
- libunistring2
- libuuid1
- libwayland-client0
- libwayland-cursor0
- libwayland-egl1
- libwayland-server0
- libx11-6
- libx11-xcb1
- libxau6
- libxcb-dri3-0
- libxcb-render0
- libxcb-shm0
- libxcb1
- libxcomposite1
- libxcursor1
- libxdamage1
- libxdmcp6
- libxext6
- libxfixes3
- libxft2
- libxi6
- libxinerama1
- libxkbcommon0
- libxrandr2
- libxrender1
- libxss1
- libxtst6
- lsb-core
when: installed_ansys.stat.exists == False
- name: install ansys requirements for autodyn
become: yes
apt:
state: latest
pkg:
- libbrotli1
- libbz2-1.0
- libcrypt1
- libcurl4-gnutls-dev
- libegl1
- libenchant-2-2
- libgfortran5
- libgl1
- libglu1-mesa
- libglvnd0
- libglx0
- libgomp1
- libgstreamer-gl1.0-0
- libgstreamer-plugins-base1.0-0
- libgstreamer1.0-0
- libgudev-1.0-0
- libharfbuzz-icu0
- libhyphen0
- libibverbs1
- libicu66
- libjavascriptcoregtk-4.0-18
- libjbig0
- libjpeg-turbo8
- libltdl7
- libnotify4
- libopenjp2-7
- liborc-0.4-0
- libpcre3-dev
- libperl-dev
- libpsl5
- libquadmath0
- libseccomp2
- libsecret-1-0
- libsoup2.4-1
- libtiff5
- libudev1
- libwebkit2gtk-4.0-37
- libwebp6
- libwebpdemux2
- libwoff1
- libxm4
- libxml2
- libxmu6
- libxshmfence1
- libxslt1.1
- libxt6
- libxxf86vm1
- uuid-dev
when: installed_ansys.stat.exists == False
- name: install ansys requirements for LS-DYNA specific (includes all autodyn)
become: yes
apt:
state: latest
pkg:
- libsdl1.2debian
- libxv1
when: installed_ansys.stat.exists == False
# nothing to add for CFX
# nothing to add for Chemkin
# nothing to add for Energico
# nothing to add for mfl
# nothing to add for reactionwb
# nothing to add for fensapice
# nothing to add for fluent
- name: install ansys requirements for fluent (includes all autodyn)
become: yes
apt:
state: latest
pkg:
- libasn1-8-heimdal
- libembree3-3
- libgssapi3-heimdal
- libhcrypto4-heimdal
- libheimbase1-heimdal
- libheimntlm0-heimdal
- libhx509-5-heimdal
- libkrb5-26-heimdal
- libldap-2.4-2
- libroken18-heimdal
- libsasl2-2
- libtbb2
- libwind0-heimdal
- libxcb-xkb1
- libxkbcommon-x11-0
- ocl-icd-opencl-dev
when: installed_ansys.stat.exists == False
# nothing to add for forte
- name: install ansys requirements for polyflow (includes all fluent)
become: yes
apt:
state: latest
pkg:
- libfontenc1
- libpam0g
- libpci3
- libxcb-xfixes0
when: installed_ansys.stat.exists == False
# nothing to add for turbogrid
- name: install ansys requirements for icemcfd (includes all fluent)
become: yes
apt:
state: latest
pkg:
- libnghttp2-14
- librtmp1
- libssh-4
when: installed_ansys.stat.exists == False
# nothing to add for aqwa
- name: install ansys requirements for mechapdl (includes all fluent)
become: yes
apt:
state: latest
pkg:
- coinor-libipopt1v5
- libdrm-amdgpu1
- libelf1
- libgtk2.0-0
- libmumps-dev
- libnuma1
- libpng-dev
- libqhull-dev
- libspooles-dev
- libtbb2
- libtiff-dev
- libtinfo5
when: installed_ansys.stat.exists == False
# nothing to add for icepak
# nothing to add for acis
- name: Create ansys tmp folder
file:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}"
state: directory
mode: "0755"
when: installed_ansys.stat.exists == False
- name: Create iso1 tmp folder
file:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso1"
state: directory
mode: "0755"
when: installed_ansys.stat.exists == False
- name: Create iso2 tmp folder
file:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso2"
state: directory
mode: "0755"
when: installed_ansys.stat.exists == False
- name: Create iso3 tmp folder
file:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso3"
state: directory
mode: "0755"
when: installed_ansys.stat.exists == False
- name: Download iso 1
amazon.aws.aws_s3:
access_key: "{{ aws_access_key }}"
secret_key: "{{ aws_secret_key }}"
bucket: 10282-70726cc2c34fcfe7d4325ef7ea151411
object: "/{{ ansys_versions[ansys_install_version_ubuntu]['url1'] }}"
dest: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url1'] }}"
mode: get
s3_url: https://s3.epfl.ch/
when: installed_ansys.stat.exists == False
- name: Download iso 2
amazon.aws.aws_s3:
access_key: "{{ aws_access_key }}"
secret_key: "{{ aws_secret_key }}"
bucket: 10282-70726cc2c34fcfe7d4325ef7ea151411
object: "/{{ ansys_versions[ansys_install_version_ubuntu]['url2'] }}"
dest: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url2'] }}"
mode: get
s3_url: https://s3.epfl.ch/
when: installed_ansys.stat.exists == False
- name: Download iso 3
amazon.aws.aws_s3:
access_key: "{{ aws_access_key }}"
secret_key: "{{ aws_secret_key }}"
bucket: 10282-70726cc2c34fcfe7d4325ef7ea151411
object: "/{{ ansys_versions[ansys_install_version_ubuntu]['url3'] }}"
dest: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url3'] }}"
mode: get
s3_url: https://s3.epfl.ch/
when: installed_ansys.stat.exists == False
- name: Mount iso1 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso1"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url1'] }}"
fstype: iso9660
opts: loop
state: mounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: Mount iso2 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso2"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url2'] }}"
fstype: iso9660
opts: loop
state: mounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: Mount iso3 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso3"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url3'] }}"
fstype: iso9660
opts: loop
state: mounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: add ansys product list
ansible.builtin.template:
src: ansys_product_installed.j2
dest: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/ansys_product_list"
when: installed_ansys.stat.exists == False
- name: Install {{ ansys_install_version_ubuntu }}
become: yes
command: "sh {{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso1/INSTALL -silent -install_dir '/usr/ansys_inc/' -media_dir2 '{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso2/' -media_dir3 '{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso3/' -licserverinfo 2325:1055:siclic1.epfl.ch"
when: installed_ansys.stat.exists == False
- name: Umount iso1 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso1"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url1'] }}"
fstype: iso9660
opts: loop
state: unmounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: Umount iso2 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso2"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url2'] }}"
fstype: iso9660
opts: loop
state: unmounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: Umount iso3 file
ansible.posix.mount:
path: "{{ tmp_ansys }}/{{ ansys_install_version_ubuntu }}/iso3"
src: "{{ tmp_ansys }}/{{ ansys_versions[ansys_install_version_ubuntu]['url3'] }}"
fstype: iso9660
opts: loop
state: unmounted
fstab: /tmp/tmp.fstab
when: installed_ansys.stat.exists == False
- name: Delete tmp content & directory
file:
state: absent
path: "{{ tmp_ansys }}"
when: installed_ansys.stat.exists == False
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment